Skip to content

Commit e30e686

Browse files
committed
Exit run_examples_as_tests with error if one test fails
1 parent a1fd3c5 commit e30e686

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

run_examples_as_tests.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -79,5 +79,6 @@ def worker(example_name):
7979

8080
print("Total time to run all examples: %fs" %(time.time() - init_time))
8181

82-
del os.environ["PYTHONOCC_OFFSCREEN_RENDERER"]
83-
del os.environ["PYTHONOCC_SHUNT_WEB_SERVER"]
82+
# if failed, exit with error
83+
if failed > 0:
84+
sys.exit(1)

0 commit comments

Comments
 (0)