tests/pthread_barrier: migrate to testrunner script
This commit is contained in:
parent
42afbb5fae
commit
1e8104f268
@ -14,3 +14,6 @@ USEMODULE += random
|
|||||||
USEMODULE += xtimer
|
USEMODULE += xtimer
|
||||||
|
|
||||||
include $(RIOTBASE)/Makefile.include
|
include $(RIOTBASE)/Makefile.include
|
||||||
|
|
||||||
|
test:
|
||||||
|
tests/01-run.py
|
||||||
|
|||||||
22
tests/pthread_barrier/tests/01-run.py
Executable file
22
tests/pthread_barrier/tests/01-run.py
Executable file
@ -0,0 +1,22 @@
|
|||||||
|
#!/usr/bin/env python3
|
||||||
|
|
||||||
|
import os
|
||||||
|
import sys
|
||||||
|
|
||||||
|
sys.path.append(os.path.join(os.environ['RIOTBASE'], 'dist/tools/testrunner'))
|
||||||
|
import testrunner
|
||||||
|
|
||||||
|
|
||||||
|
def testfunc(child):
|
||||||
|
child.expect('START')
|
||||||
|
for i in range(4):
|
||||||
|
child.expect('Start {}'.format(i + 1))
|
||||||
|
child.expect('Done 2')
|
||||||
|
child.expect('Done 1')
|
||||||
|
child.expect('Done 3')
|
||||||
|
child.expect('Done 4')
|
||||||
|
child.expect('SUCCESS')
|
||||||
|
|
||||||
|
|
||||||
|
if __name__ == "__main__":
|
||||||
|
sys.exit(testrunner.run(testfunc))
|
||||||
Loading…
x
Reference in New Issue
Block a user