Add a wait for the animation to complete during event creation.

This commit is contained in:
Tom Price
2016-03-17 17:47:02 +00:00
parent cd82712742
commit 10c5ea3e7c

View File

@@ -324,7 +324,10 @@ class EventTest(LiveServerTestCase):
'//select[@id="id_organisation"]//option[@selected="selected"]')
self.assertEqual(obj.pk, int(option.get_attribute("value")))
# Create veneue
# Create venue
wait = WebDriverWait(self.browser, 10) #setup WebDriverWait to use later (to wait for animations)
wait.until(animation_is_finished())
add_button = self.browser.find_element_by_xpath(
'//a[@data-target="#id_venue" and contains(@href, "add")]')
add_button.click()