Skip to content

tests: use start_network instead of ethos directly#13802

Closed
miri64 wants to merge 1 commit intoRIOT-OS:masterfrom
miri64:tests/fix/use-start_network
Closed

tests: use start_network instead of ethos directly#13802
miri64 wants to merge 1 commit intoRIOT-OS:masterfrom
miri64:tests/fix/use-start_network

Conversation

@miri64
Copy link
Member

@miri64 miri64 commented Apr 3, 2020

Contribution description

On some platforms (e.g. Arch Linux or newer Ubuntu versions) the TAP interface does not come up once connected and must be set up manually. This is already done in the start_network.sh script so let's just use that instead of pure ethos.

Testing procedure

The tests in question should still work for boards supporting ethos:

cd tests/${TEST}
export BOARD=samr21-xpro
make flash
sudo make test

Issues/PRs references

See #13734 (comment)

On some platforms (e.g. Arch Linux) the TAP interface does not come up
once connected and must be set up manually. This is already done in the
`start_network.sh` script so let's just use that instead of pure
`ethos`.
@miri64 miri64 added Type: enhancement The issue suggests enhanceable parts / The PR enhances parts of the codebase / documentation Area: tests Area: tests and testing framework Area: tools Area: Supplementary tools labels Apr 3, 2020
@miri64 miri64 added this to the Release 2020.04 milestone Apr 3, 2020
@miri64 miri64 requested a review from leandrolanzieri April 3, 2020 12:11
@benpicco
Copy link
Contributor

benpicco commented Apr 3, 2020

Hard to tell if the test was already broken on master 😕

% sudo make BOARD=saml10-xpro PORT=/dev/ttyACM1 test 
[sudo] password for benpicco: 
make[1]: Nothing to be done for 'all'.
Timeout in expect script at "child.expect(r"HWaddr: (?P<hwaddr>[A-Fa-f:0-9]+)\s")" (tests/gnrc_ipv6_ext/tests/01-run.py:598)

make: *** [/home/benpicco/dev/RIOT/tests/gnrc_ipv6_ext/../../Makefile.include:733: test] Error 1

@benpicco
Copy link
Contributor

benpicco commented Apr 3, 2020

Ah now I see my mistake - the PORT=/dev/ttyACM1 does not get exported into the sudo environment.

I unplugged the other board occupying /dev/ttyACM0, now the test is progressing further

sudo make BOARD=samr21-xpro test
make[1]: Nothing to be done for 'all'.
......FAILED
Timeout in expect script at "child.expect(r"~~ SNIP  0 - size:\s+(\d+) byte, type: NETTYPE_\w+ \(\d+\)")" (tests/gnrc_ipv6_ext/tests/01-run.py:135)

make: *** [/home/benpicco/dev/RIOT/tests/gnrc_ipv6_ext/../../Makefile.include:733: test] Error 1

But that failure should be unrelated to this PR.

The tap0 interface keeps lingering around after the failed test though.

@miri64
Copy link
Member Author

miri64 commented Apr 3, 2020

The tap0 interface keeps lingering around after the failed test though.

Again: this should be removed by the cleanup function in the start_network.sh script.

@miri64
Copy link
Member Author

miri64 commented Apr 3, 2020

The tap0 interface keeps lingering around after the failed test though.

Again: this should be removed by the cleanup function in the start_network.sh script.

Mkay.. if testrunner just calls SIGKILL without warning the best script cleanup does not help.....

Anyway... #12994 (comment) the issue that triggered this PR does not seem to be about ethos after all... The cleanup issue persists, but for now, I am closing this PR.

@miri64 miri64 closed this Apr 3, 2020
@miri64 miri64 deleted the tests/fix/use-start_network branch April 3, 2020 21:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Area: tests Area: tests and testing framework Area: tools Area: Supplementary tools Type: enhancement The issue suggests enhanceable parts / The PR enhances parts of the codebase / documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants