Skip to content

Commit 882df81

Browse files
committed
Allow not exiting after spin failure
1 parent 62472ad commit 882df81

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

spin/tests/testutil.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,10 @@ def spin(*args, **user_kwargs):
3434
if p.returncode != 0:
3535
print(p.stdout.decode("utf-8"), end="")
3636
print(p.stderr.decode("utf-8"), end="")
37-
sys.exit(p.returncode)
37+
# Exit unless the spin call explicitly asks us not to
38+
# by setting sys_exit=False
39+
if user_kwargs.get("sys_exit", True):
40+
sys.exit(p.returncode)
3841
return p
3942

4043

0 commit comments

Comments
 (0)