tests/run-tests: Be sure to close Pyboard object on completion.
So underlying device was properly closed too.
This commit is contained in:
parent
9b3f423c14
commit
5b2db4bb51
|
@ -456,7 +456,10 @@ def main():
|
|||
# clear search path to make sure tests use only builtin modules
|
||||
os.environ['MICROPYPATH'] = ''
|
||||
|
||||
if not run_tests(pyb, tests, args):
|
||||
res = run_tests(pyb, tests, args)
|
||||
if pyb:
|
||||
pyb.close()
|
||||
if not res:
|
||||
sys.exit(1)
|
||||
|
||||
if __name__ == "__main__":
|
||||
|
|
Loading…
Reference in New Issue