Skip to content

Repository files navigation

SeleniumLibrary localisation project

This project contains localizations for the Robot Framework SeleniumLibrary:

New languages can be added by creating a translation_xx.json file and adding its definition to init.py. Replace xx with the language code.

This project uses SeleniumLibrary Python plugin API to provide translation_xx.json file for the Seleniumlibrary. SeleniumLibrary searches Python plugins by using naming convention: robotframework_seleniumlibrary_translation. This module fulfils the SeleniumLibrary translation API and provides get_language method. The method return a list of dictionaries:

[
    {"language": "fi", "path": "/path/to/translation_fi.json"},
    {"language": "fr", "path": "/path/to/translation_fr.json"}
]

Which SeleniumLibrary will use to match correct translation from all the found Python plugins. Language search is enabled when SeleniumLibrary is imported with:

*** Settings ***
Library    SeleniumLibrary    language=fi

For French, use language=fr:

*** Settings ***
Library    SeleniumLibrary    language=fr

*** Test Cases ***
Close Browsers In French
    Fermer tous les navigateurs

Detect changes in documentation

The translation_xx.json contains sha256 sum, which is generated by the SeleniumLibrary. The sha256 is the checksum of the original documentation of the SeleniumLibrary documentation. The checksum is used by selib translation --compare robotframework_seleniumlibrary_translation/translation_fi.json command to compare the library documentation with the translation file. The command lists keywords that need updating or are missing. Use translation_fr.json to check French.

About

Provides translation for robotframework-seleniumlibrary

Topics

Resources

Stars

2 stars

Watchers

2 watching

Forks

Releases

Packages

Used by

Contributors

Languages