Skip to content

Commit e991523

Browse files
committed
Fix test_fail_fast
It seems this never did what it was supposed to test.
1 parent 051f081 commit e991523

1 file changed

Lines changed: 6 additions & 5 deletions

File tree

tests/test_shed_lint.py

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -58,11 +58,12 @@ def test_invalid_nested(self):
5858

5959
def test_fail_fast(self):
6060
# Created a nested repository with one good and one
61-
# invalid repository and make sure it runs and produces
62-
# a 254 (it ran to completion but one or more things failed
63-
# )
64-
with self._isolate_repo("bad_invalid_yaml"):
65-
r = self._check_exit_code(["shed_lint", "--fail_fast"],
61+
# invalid repository and make sure it exits immediately with -1.
62+
with self._isolate() as f:
63+
for name in ["bad_invalid_yaml", "single_tool_exclude"]:
64+
self._copy_repo(name, join(f, name))
65+
self._copy_repo(name, join(f, name))
66+
r = self._check_exit_code(["shed_lint", "-r" ,"--fail_fast"],
6667
exit_code=-1)
6768
assert isinstance(r.exception, RuntimeError)
6869

0 commit comments

Comments
 (0)