Skip to content

Commit 01b4ef3

Browse files
authored
Merge branch 'main' into philimon/fix_fingerprint_test
2 parents b52d6e2 + 31631ab commit 01b4ef3

File tree

7 files changed

+590
-16
lines changed

7 files changed

+590
-16
lines changed
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
{
2+
"url": "http://127.0.0.1:8080/mediamarkt_ad.html",
3+
"field_mapping": {
4+
"given_name": "8c7da706-f38b-4a73-9676-9002d73d42ce",
5+
"family_name": "11e319f4-799c-4dc7-b263-ba7579f925b0",
6+
"street_address": "5e202852-df33-4dca-810d-010cc4c2357b",
7+
"email": "36b2f5e8-aa5e-4d1d-9831-75d79fbdc7a3",
8+
"telephone": "4fce2ff8-f354-49ca-9d7e-9a0115bbf578"
9+
},
10+
"form_field": "*[data-moz-autofill-inspect-id='{name}']",
11+
"fields": [
12+
"8c7da706-f38b-4a73-9676-9002d73d42ce",
13+
"11e319f4-799c-4dc7-b263-ba7579f925b0",
14+
"5e202852-df33-4dca-810d-010cc4c2357b",
15+
"36b2f5e8-aa5e-4d1d-9831-75d79fbdc7a3",
16+
"4fce2ff8-f354-49ca-9d7e-9a0115bbf578"
17+
]
18+
}
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
{
2+
"url": "http://127.0.0.1:8080/mediamarkt_cc.html",
3+
"field_mapping": {
4+
"card_number": "64541173-1c23-4398-9e42-9085d76991f4",
5+
"name": "4edb0e50-ed4c-4142-ab00-462daa5ae5e3",
6+
"expiration_date": "ef27ace4-89d6-48cf-a25e-32e2adad969e"
7+
},
8+
"form_field": "*[data-moz-autofill-inspect-id='{name}']",
9+
"fields": [
10+
"64541173-1c23-4398-9e42-9085d76991f4",
11+
"4edb0e50-ed4c-4142-ab00-462daa5ae5e3",
12+
"ef27ace4-89d6-48cf-a25e-32e2adad969e"
13+
]
14+
}

l10n_CM/run_l10n.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
valid_flags = {"--run-headless", "-n", "--reruns"}
1414
flag_with_parameter = {"-n", "--reruns"}
1515
valid_region = {"US", "CA", "DE", "FR"}
16-
valid_sites = {"demo", "amazon", "walmart"}
16+
valid_sites = {"demo", "amazon", "walmart", "mediamarkt"}
1717
live_sites = []
1818

1919
LOCALHOST = "127.0.0.1"

l10n_CM/sites/mediamarkt/DE/mediamarkt_ad.html

Lines changed: 540 additions & 0 deletions
Large diffs are not rendered by default.

l10n_CM/sites/mediamarkt/DE/mediamarkt_cc.html

Lines changed: 4 additions & 0 deletions
Large diffs are not rendered by default.

tests/address_bar_and_search/test_search_suggestions.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99

1010
# Constants
1111
SEARCH_TERM_SPONSORED = "iphone"
12-
SEARCH_TERM_NON_SPONSORED = "wiki"
12+
SEARCH_TERM_NON_SPONSORED = "wikimedia"
1313
RETRY_LIMIT = 5
1414
SECONDS = 3
1515

@@ -72,5 +72,5 @@ def test_search_suggests_enabled(driver: Firefox):
7272
with driver.context(driver.CONTEXT_CHROME):
7373
nav.get_element("firefox-suggest")
7474
titles = nav.get_elements("suggestion-titles")
75-
found_non_sponsored = any("wikipedia" in title.text for title in titles)
75+
found_non_sponsored = any("Wikipedia" in title.text for title in titles)
7676
assert found_non_sponsored, "Non-sponsored suggestion not found"

tests/preferences/test_clear_cookie_data.py

Lines changed: 11 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,13 @@ def test_case():
1010
return "143627"
1111

1212

13+
def open_clear_cookies_data_dialog(about_prefs: AboutPrefs, ba: BrowserActions):
14+
about_prefs.open()
15+
clear_data_popup = about_prefs.press_button_get_popup_dialog_iframe("Clear Data")
16+
ba.switch_to_iframe_context(clear_data_popup)
17+
return about_prefs.get_clear_cookie_data_value()
18+
19+
1320
def test_clear_cookie_data(driver: Firefox):
1421
"""
1522
C143627: Cookies and site data can be cleared via the "Clear Data" panel
@@ -18,27 +25,18 @@ def test_clear_cookie_data(driver: Firefox):
1825
about_prefs = AboutPrefs(driver, category="privacy")
1926
ba = BrowserActions(driver)
2027

21-
def open_clear_cookies_data_dialog():
22-
about_prefs.open()
23-
clear_data_popup = about_prefs.press_button_get_popup_dialog_iframe(
24-
"Clear Data"
25-
)
26-
ba.switch_to_iframe_context(clear_data_popup)
27-
2828
# Visit a site to get a cookie added to saved data
29-
driver.get("https://www.firefox.com")
29+
driver.get("https://www.wikipedia.com")
3030

3131
# Navigate to the clear data dialog of about:preferences#privacy
32-
open_clear_cookies_data_dialog()
33-
3432
# Check for a non-zero value of the 'Cookies and site data' option
35-
cookie_value = about_prefs.get_clear_cookie_data_value()
33+
cookie_value = open_clear_cookies_data_dialog(about_prefs, ba)
3634
assert cookie_value > 0
3735

3836
# Then clear the cookies and site data
3937
about_prefs.get_element("clear-data-accept-button").click()
4038

4139
# Finally, check the value of the dialog option, it should be 0
42-
open_clear_cookies_data_dialog()
43-
cookie_value2 = about_prefs.get_clear_cookie_data_value()
40+
41+
cookie_value2 = open_clear_cookies_data_dialog(about_prefs, ba)
4442
assert cookie_value2 == 0

0 commit comments

Comments
 (0)