[Fuego] [PATCH 14/16] Use a fixed language for Selenium Chrome-WebDriver

Guilherme Campos Camargo guicc at profusion.mobi
Thu Mar 29 00:08:30 UTC 2018


This will allow elements to be searched by text (english) disregarding
eventual page translations that may take place depending on the system's
locale.

Signed-off-by: Guilherme Campos Camargo <guicc at profusion.mobi>
---
 engine/tests/Functional.fuegotest/test_run.py | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/engine/tests/Functional.fuegotest/test_run.py b/engine/tests/Functional.fuegotest/test_run.py
index 91d0666..0370b6f 100755
--- a/engine/tests/Functional.fuegotest/test_run.py
+++ b/engine/tests/Functional.fuegotest/test_run.py
@@ -419,6 +419,8 @@ class SeleniumContainerSession():
         options.add_argument('headless')
         options.add_argument('no-sandbox')
         options.add_argument('window-size=1200x600')
+        options.add_experimental_option(
+            'prefs', {'intl.accept_languages': 'en,en_US'})
 
         self.driver = webdriver.Chrome(chrome_options=options)
         self.driver.implicitly_wait(3)
-- 
2.16.2



More information about the Fuego mailing list