1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2025-12-31 17:31:18 +01:00

tests/thread_msg_seq: migrate to testrunner script

This commit is contained in:
Alexandre Abadie 2017-11-04 17:12:24 +01:00
parent 3a7621d0cb
commit 3217648aa6
2 changed files with 30 additions and 1 deletions

View File

@ -1,8 +1,11 @@
APPLICATION = thread_msg_seq
include ../Makefile.tests_common
BOARD_INSUFFICIENT_MEMORY := nucleo32-f031 nucleo32-f042 stm32f0discovery
BOARD_INSUFFICIENT_MEMORY := nucleo32-f031 nucleo32-f042
DISABLE_MODULE += auto_init
include $(RIOTBASE)/Makefile.include
test:
tests/01-run.py

View File

@ -0,0 +1,26 @@
#!/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")
child.expect("THREADS CREATED")
child.expect("THREAD nr1 \(pid:3\) start")
child.expect("THREAD nr1 \(pid:3\) end.")
child.expect("THREAD nr2 \(pid:4\) start")
child.expect("THREAD nr3 \(pid:5\) start")
child.expect("Got msg from pid 3: \"nr1\"")
child.expect("THREAD nr2 \(pid:4\) end.")
child.expect("Got msg from pid 4: \"nr2\"")
child.expect("THREAD nr3 \(pid:5\) end.")
child.expect("Got msg from pid 5: \"nr3\"")
child.expect("SUCCESS")
if __name__ == "__main__":
sys.exit(testrunner.run(testfunc))