Skip to content
Snippets Groups Projects
Commit 242b3736 authored by Ben Patterson's avatar Ben Patterson
Browse files

Merge pull request #8429 from edx/benp/fix-flaky-lms-answer-jun2015

Fix flaky lettuce test. TE-572.
parents 7d338922 e54ce295
No related branches found
Tags release-2021-04-26-14.10
No related merge requests found
......@@ -172,8 +172,10 @@ def assert_answer_mark(_step, problem_type, isnt_marked, correctness):
# At least one of the correct selectors should be present
for sel in PROBLEM_DICT[problem_type][correctness]:
if bool(isnt_marked):
world.wait_for(lambda _: world.is_css_not_present(sel)) # pylint: disable=cell-var-from-loop
has_expected = world.is_css_not_present(sel)
else:
world.css_find(sel) # css_find includes a wait_for pattern
has_expected = world.is_css_present(sel)
# As soon as we find the selector, break out of the loop
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment