Skip to content

MarketSquare/robotframework-seleniumlibrary-translation

Folders and files

NameName
Last commit message
Last commit date
Mar 1, 2025
Feb 22, 2025
Mar 1, 2025
Feb 22, 2025
Jun 18, 2024
Mar 1, 2025
May 30, 2024
Mar 7, 2025
Mar 1, 2025
Mar 18, 2025
Feb 22, 2025

Repository files navigation

SeleniumLibrary localisation project

This project contains all localizations for the Robot Framework SeleniumLibrary. Currently project contains only one translation, Finnish , but new languages can be added by creating translation_xx.json file and adding the definition to init.py file. The xx should be replaced with correct 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"}]

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

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 sellib translation --compare robotframework_seleniumlibrary_translation/translation.json command to compare translation between the library and translation file. Command will display a list of keywords which needs updating or are missing from the translation.json file.