Commit 0071c9d3 by Ben Patterson

OwnLearnerProfile tests multiprocessing support.

Fix a flaky test condition that only occurs in
multiprocessing mode. Make the page definition more
specific; the previous implementation would not fully
render all objects in time.

Avoid race condition related to events order (in faster,
multiprocess testing, the order is not exactly the same since
some events arrive at once).
parent 8610b6de
...@@ -43,7 +43,7 @@ class LearnerProfilePage(FieldsMixin, PageObject): ...@@ -43,7 +43,7 @@ class LearnerProfilePage(FieldsMixin, PageObject):
""" """
Check if browser is showing correct page. Check if browser is showing correct page.
""" """
return self.q(css='body.view-profile').present return self.q(css='body.view-profile .account-settings-container').present
@property @property
def privacy(self): def privacy(self):
......
...@@ -1381,7 +1381,11 @@ class EditTeamTest(TeamFormActions): ...@@ -1381,7 +1381,11 @@ class EditTeamTest(TeamFormActions):
} }
}, },
] ]
with self.assert_events_match_during(event_filter=self.only_team_events, expected_events=expected_events): with self.assert_events_match_during(
event_filter=self.only_team_events,
expected_events=expected_events,
in_order=False,
):
self.team_management_page.submit_form() self.team_management_page.submit_form()
self.team_page.wait_for_page() self.team_page.wait_for_page()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment