Skip to content

Commit 284a7d4

Browse files
authored
Anca/ Fix addon-suggestion (#895)
* Fix addon-suggestion * Update list * Reduce the wait time
1 parent 700323d commit 284a7d4

File tree

4 files changed

+11
-13
lines changed

4 files changed

+11
-13
lines changed

modules/browser_object_autofill_popup.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,5 +141,6 @@ def verify_update_password_doorhanger(self, nav, expected_text):
141141

142142
# Verify the doorhanger text
143143
self.expect(
144-
lambda _: expected_text in self.get_element("password-update-doorhanger").text
144+
lambda _: expected_text
145+
in self.get_element("password-update-doorhanger").text
145146
)

modules/page_object_autofill.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -860,8 +860,8 @@ def generate_secure_password(self, context_menu):
860860
# Wait until the password field is actually filled
861861
self.parent.expect(
862862
lambda _: (
863-
(elem := self.parent.get_element("password-login-field"))
864-
and elem.get_attribute("value") not in ("", None)
863+
(elem := self.parent.get_element("password-login-field"))
864+
and elem.get_attribute("value") not in ("", None)
865865
)
866866
)
867867

tests/address_bar_and_search/test_addon_suggestion.py

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6,17 +6,16 @@
66

77
from modules.browser_object import Navigation
88

9-
WAIT_TIMEOUT = 10
109
ADDONS_BASE_URL = "https://addons.mozilla.org/en-US/firefox/addon/"
1110

11+
# pending answers from search team about FX changes here, only grammar works as before
1212
INPUT_TO_ADDON_NAME = {
13-
"clips": "video-downloadhelper",
13+
"video download": "video-downloadhelper",
1414
"grammar": "languagetool",
15-
"Temp mail": "private-relay",
16-
"pics search": "search_by_image",
15+
"alias": "private-relay",
16+
"image finder": "search_by_image",
1717
"darker theme": "darkreader",
18-
"privacy": "privacy-badger17",
19-
"read aloud": "read-aloud",
18+
"accessibility reade": "read-aloud",
2019
}
2120

2221

@@ -28,7 +27,7 @@ def test_case():
2827
@pytest.mark.noxvfb
2928
def test_addon_suggestion_based_on_search_input(driver: Firefox):
3029
"""
31-
C2234714 - Verify that the address bar suggests relevant add-ons based on search input.
30+
C3029292 - Verify that the address bar suggests relevant add-ons based on search input.
3231
"""
3332
nav = Navigation(driver)
3433
nav.set_awesome_bar()

tests/password_manager/test_auto_saved_generated_password_context_menu.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,9 +36,7 @@ def test_auto_saved_generated_password_context_menu(driver: Firefox):
3636
login_autofill.LoginForm(login_autofill).generate_secure_password(context_menu)
3737

3838
# Verify the update doorhanger is displayed
39-
autofill_popup_panel.verify_update_password_doorhanger(
40-
nav, UPDATE_DOORHANGER_TEXT
41-
)
39+
autofill_popup_panel.verify_update_password_doorhanger(nav, UPDATE_DOORHANGER_TEXT)
4240

4341
# Navigate to about:logins page
4442
tabs.switch_to_new_tab()

0 commit comments

Comments
 (0)