Skip to content

Commit f29ba48

Browse files
committed
test: Fix use of allowed_failures in pathological_tests.py
The test needs to check if the test description is a valid key in the allowed_failures dictionary instead of attempting to fetch from the dictionary as most of the descriptions are not present in the dictionary leading to a missing key error at runtime. Signed-off-by: Keith Packard <keithp@keithp.com>
1 parent 2cd7a1a commit f29ba48

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

test/pathological_tests.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -146,12 +146,12 @@ def run_test(inp, regex):
146146
p.terminate()
147147
p.join()
148148
print('[TIMED OUT]')
149-
if allowed_failures[description]:
149+
if description in allowed_failures:
150150
ignored += 1
151151
else:
152152
errored += 1
153153
elif p.exitcode != 0:
154-
if allowed_failures[description]:
154+
if description in allowed_failures:
155155
ignored += 1
156156
else:
157157
errored += 1

0 commit comments

Comments
 (0)