NetworkManager/src/devices/tests
Thomas Haller 06569528ce arping/tests: better handle wait timeout for test IPv4 DAD
The test tries to do IPv4 DAD. That necessarily involves waiting
for a timeout. Since the NMArpingManager spawns arping processes,
the precise timings depend on the load of the machine and may be
large in some cases.

Usually, our test would run fast to successful completion.
However, sometimes, it can take several hundered milliseconds.

Instead of increasing the timeout to a large value (which would
needlessly extend the run time of our tests in the common cases),
try first with a reasonably short timeout. A timeout which commonly
results in success. If the test with the short timeout fails, just
try again with an excessively large timeout.

This saves about 400 msec for the common case, but extends the
races that we saw where not even 250 msec of wait time were
sufficient.

(cherry picked from commit 059d34a27f)
2018-03-15 11:41:57 +01:00
..
test-arping.c arping/tests: better handle wait timeout for test IPv4 DAD 2018-03-15 11:41:57 +01:00
test-lldp.c all: use nm_close() instead of close() 2017-11-14 15:17:02 +01:00