summaryrefslogtreecommitdiffstatshomepage
path: root/tests
diff options
context:
space:
mode:
authorPaul Sokolovsky <pfalcon@users.sourceforge.net>2017-04-02 20:47:44 +0300
committerPaul Sokolovsky <pfalcon@users.sourceforge.net>2017-04-02 20:49:16 +0300
commit5b2db4bb51548ce5f20b5f3fa5890c50514ec884 (patch)
treeda8e77ee93d29d7f78c2c7a10b8fea74bf31da3c /tests
parent9b3f423c14af65f8f273d8ab3f3db68b191c3794 (diff)
downloadmicropython-5b2db4bb51548ce5f20b5f3fa5890c50514ec884.tar.gz
micropython-5b2db4bb51548ce5f20b5f3fa5890c50514ec884.zip
tests/run-tests: Be sure to close Pyboard object on completion.
So underlying device was properly closed too.
Diffstat (limited to 'tests')
-rwxr-xr-xtests/run-tests5
1 files changed, 4 insertions, 1 deletions
diff --git a/tests/run-tests b/tests/run-tests
index e8dc2ba580..43db15097e 100755
--- a/tests/run-tests
+++ b/tests/run-tests
@@ -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__":