Commit dae5cdfc by Ben Patterson

Fix empty promise. It was always evaluating to true.

This addresses TNL-1808 (and likely other flaky tests
in this area).
parent 9edda950
...@@ -400,7 +400,7 @@ class CohortManagementSection(PageObject): ...@@ -400,7 +400,7 @@ class CohortManagementSection(PageObject):
""" """
if wait_for_messages: if wait_for_messages:
EmptyPromise( EmptyPromise(
lambda: self.q(css=self._bounded_selector(title_css)).results != 0, lambda: len(self.q(css=self._bounded_selector(title_css)).results) != 0,
"Waiting for messages to appear" "Waiting for messages to appear"
).fulfill() ).fulfill()
message_title = self.q(css=self._bounded_selector(title_css)) message_title = self.q(css=self._bounded_selector(title_css))
......
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