Skip to content

Commit b622f0c

Browse files
committed
initial commit
1 parent 76974d1 commit b622f0c

File tree

3 files changed

+90
-1
lines changed

3 files changed

+90
-1
lines changed

modules/data/about_prefs.components.json

Lines changed: 58 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@
7878
},
7979

8080
"prefs-button": {
81-
"selectorData": "button[label=\"{name}\"]",
81+
"selectorData": "button[label='{name}']",
8282
"strategy": "css",
8383
"groups": []
8484
},
@@ -153,6 +153,63 @@
153153
"groups": []
154154
},
155155

156+
"language-set-alternatives-button": {
157+
"selectorData": "manageBrowserLanguagesButton",
158+
"strategy": "id",
159+
"groups": []
160+
},
161+
162+
"language-set-alternatives-popup-select-language": {
163+
"selectorData": "availableLocales",
164+
"strategy": "id",
165+
"groups": [
166+
"doNotCache"
167+
]
168+
},
169+
170+
"language-set-alternatives-popup-select-language-search-more": {
171+
"selectorData": "menuitem[label='Search for more languages…']",
172+
"strategy": "css",
173+
"groups": []
174+
},
175+
176+
"language-set-alternatives-popup-select-language-italian": {
177+
"selectorData": "menuitem[label='Italiano']",
178+
"strategy": "css",
179+
"groups": []
180+
},
181+
182+
"languages-shadow-root": {
183+
"selectorData": "dialog[buttons='accept,cancel,help']",
184+
"strategy": "css",
185+
"groups": []
186+
},
187+
188+
"language-accept-button": {
189+
"selectorData": "button[dlgtype='accept']",
190+
"strategy": "css",
191+
"shadowParent": "languages-shadow-root",
192+
"groups": []
193+
},
194+
195+
"language-add-button": {
196+
"selectorData": "add",
197+
"strategy": "id",
198+
"groups": []
199+
},
200+
201+
"language-list-item": {
202+
"selectorData": "locale-it",
203+
"strategy": "id",
204+
"groups": []
205+
},
206+
207+
"html-root": {
208+
"selectorData": "preferences-root",
209+
"strategy": "id",
210+
"groups": []
211+
},
212+
156213
"home-new-tabs-dropdown": {
157214
"selectorData": "newTabMode",
158215
"strategy": "id",

tests/language_packs/conftest.py

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
import pytest
2+
3+
4+
@pytest.fixture()
5+
def suite_id():
6+
return ("S22801", "Language Packs")
7+
8+
9+
@pytest.fixture()
10+
def set_prefs():
11+
"""Set prefs"""
12+
return [
13+
("intl.multilingual.downloadEnabled", True),
14+
("intl.multilingual.enabled", True),
15+
("intl.multilingual.liveReload", True),
16+
]
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
from time import sleep
2+
3+
from selenium.webdriver import Firefox
4+
5+
from modules.page_object import AboutPrefs, AboutAddons, Navigation
6+
7+
def test_language_pack_install_from_addons(driver: Firefox):
8+
""""
9+
C1549408: verify that installing a language pack from about:addons will correctly change the locale
10+
"""
11+
about_prefs = AboutPrefs(driver, category="general")
12+
about_addons = AboutAddons(driver)
13+
nav = Navigation(driver).open()
14+
15+
nav.search("https://addons.mozilla.org/en-US/firefox/language-tools/")
16+
sleep(10)

0 commit comments

Comments
 (0)