summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorMarijke Luttekes <mail@marijkeluttekes.dev>2024-04-17 16:30:13 +0200
committerSarah Boyce <42296566+sarahboyce@users.noreply.github.com>2024-04-17 17:38:04 +0200
commit2be37b253341cfd1f1363c533e6f896230f047a7 (patch)
tree43634e6ae58174287ee6823b9d51bb2028116263 /tests
parentf0d50a937910571fc4adb7e6fb91045cdc215aa8 (diff)
Made SeleniumTests.test_inline_add_another_widgets less flaky by adding explicit wait.
Diffstat (limited to 'tests')
-rw-r--r--tests/admin_views/test_autocomplete_view.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/tests/admin_views/test_autocomplete_view.py b/tests/admin_views/test_autocomplete_view.py
index 8f56dd8314..dc3789fc5b 100644
--- a/tests/admin_views/test_autocomplete_view.py
+++ b/tests/admin_views/test_autocomplete_view.py
@@ -576,7 +576,8 @@ class SeleniumTests(AdminSeleniumTestCase):
def assertNoResults(row):
elem = row.find_element(By.CSS_SELECTOR, ".select2-selection")
- elem.click() # Open the autocomplete dropdown.
+ with self.select2_ajax_wait():
+ elem.click() # Open the autocomplete dropdown.
results = self.selenium.find_element(By.CSS_SELECTOR, ".select2-results")
self.assertTrue(results.is_displayed())
option = self.selenium.find_element(