diff --git a/portal/tests/test_independent_student.py b/portal/tests/test_independent_student.py index 99261cceb..332dae87f 100644 --- a/portal/tests/test_independent_student.py +++ b/portal/tests/test_independent_student.py @@ -144,6 +144,7 @@ def test_delete_indy_account(self): delete_button_confirm.click() # check if can still login to the account + time.sleep(0.9) page = self.go_to_homepage() assert page.go_to_independent_student_login_page().independent_student_login_failure(email, password) diff --git a/portal/tests/test_teacher.py b/portal/tests/test_teacher.py index c45b1f644..9b44ff182 100644 --- a/portal/tests/test_teacher.py +++ b/portal/tests/test_teacher.py @@ -759,8 +759,8 @@ def test_make_admin_popup(self): assert page.element_exists((By.CLASS_NAME, "popup-box__msg")) - def test_delete_account(self): FADE_TIME = 0.9 # often fails if lower + def test_delete_account(self): email, password = signup_teacher_directly() create_organisation_directly(email) @@ -817,6 +817,7 @@ def test_delete_account(self): page.browser.find_element_by_id("delete_button").click() # back to homepage + time.sleep(FADE_TIME) assert page.browser.find_element_by_class_name("banner--homepage") # user should not be able to login now