1
0
mirror of https://github.com/django/django.git synced 2024-12-22 17:16:24 +00:00

Removed blocking wait in admin inlines selenium test.

find_elements_by_css_selector() implicitly waits the default timeout
(10 seconds) looking for missing elements.
This commit is contained in:
Carlton Gibson 2021-09-22 08:17:48 +02:00 committed by GitHub
parent b0ed619303
commit e0a56ad3c8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1644,7 +1644,9 @@ class SeleniumTests(AdminSeleniumTestCase):
self.selenium.execute_script('window.scrollTo(0, %s);' % hide_link.location['y'])
hide_link.click()
self.wait_until_invisible(field_name)
with self.wait_page_loaded():
self.selenium.find_element_by_xpath('//input[@value="Save"]').click()
with self.disable_implicit_wait():
self.assertEqual(
len(self.selenium.find_elements_by_css_selector(stacked_inline_formset_selector + '.collapsed')), 0
)