mirror of
https://github.com/RIOT-OS/RIOT.git
synced 2024-12-29 04:50:03 +01:00
tests/nordic_softdevice: cleanup test script and fix test
Adding a 1s delay before sending ifconfig makes this test works reliably because it gives the softdevice enough time to get in a ready state.
This commit is contained in:
parent
97d5040525
commit
98e17c2736
@ -1,14 +1,17 @@
|
||||
#!/usr/bin/env python3
|
||||
|
||||
import sys
|
||||
import time
|
||||
from testrunner import run
|
||||
|
||||
|
||||
def testfunc(child):
|
||||
child.expect("All up, running the shell now")
|
||||
child.expect_exact("All up, running the shell now")
|
||||
child.expect_exact(">")
|
||||
time.sleep(1) # Wait 1s to let some time for the interface to be fully ready
|
||||
child.sendline("ifconfig")
|
||||
child.expect(r"Iface\s+(\d+)\s+HWaddr:")
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
sys.exit(run(testfunc, timeout=1, echo=False))
|
||||
sys.exit(run(testfunc))
|
||||
|
Loading…
Reference in New Issue
Block a user