Skip to content
Snippets Groups Projects
Commit 0f7f9fe9 authored by Martine Lenders's avatar Martine Lenders
Browse files

unittests: fix for python3

parent 94bbd055
No related branches found
No related tags found
No related merge requests found
...@@ -13,7 +13,8 @@ DEFAULT_TIMEOUT = 5 ...@@ -13,7 +13,8 @@ DEFAULT_TIMEOUT = 5
def main(): def main():
env = os.environ.copy() env = os.environ.copy()
child = spawn("make term", env=env, timeout=DEFAULT_TIMEOUT) child = spawn("make term", env=env, timeout=DEFAULT_TIMEOUT,
encoding="utf-8")
child.logfile = sys.stdout child.logfile = sys.stdout
try: try:
...@@ -23,7 +24,7 @@ def main(): ...@@ -23,7 +24,7 @@ def main():
# make reset yields error on some boards even if successful # make reset yields error on some boards even if successful
pass pass
try: try:
child.expect(r"OK \([0-9]+ tests\)") child.expect(u"OK \\([0-9]+ tests\\)")
except TIMEOUT: except TIMEOUT:
print("There where errors in the unittests") print("There where errors in the unittests")
return 1 return 1
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment