Skip to content

Commit 5b2db4b

Browse files
committed
tests/run-tests: Be sure to close Pyboard object on completion.
So underlying device was properly closed too.
1 parent 9b3f423 commit 5b2db4b

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

tests/run-tests

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -456,7 +456,10 @@ def main():
456456
# clear search path to make sure tests use only builtin modules
457457
os.environ['MICROPYPATH'] = ''
458458

459-
if not run_tests(pyb, tests, args):
459+
res = run_tests(pyb, tests, args)
460+
if pyb:
461+
pyb.close()
462+
if not res:
460463
sys.exit(1)
461464

462465
if __name__ == "__main__":

0 commit comments

Comments
 (0)