Page MenuHomeFreeBSD

tests/arp: Add a 1-second tolerance
ClosedPublic

Authored by olivier on Apr 25 2025, 8:16 PM.
Tags
None
Referenced Files
Unknown Object (File)
Thu, Jul 17, 6:05 AM
Unknown Object (File)
Wed, Jul 16, 9:57 AM
Unknown Object (File)
Mon, Jul 7, 11:44 AM
Unknown Object (File)
Fri, Jul 4, 11:51 PM
Unknown Object (File)
Jul 2 2025, 5:44 AM
Unknown Object (File)
Jun 30 2025, 6:34 AM
Unknown Object (File)
Jun 25 2025, 2:56 PM
Unknown Object (File)
Jun 13 2025, 12:50 AM

Details

Summary

This test could be flaky when using the regression test VM because there is only a 1-second delay:

Fail: stdout does not match expected value
--- /tmp/kyua.zDf9hw/2/work/atf-check.9XBKIW    2025-04-25 19:33:19.991158000 +0000
+++ /tmp/kyua.zDf9hw/2/work/check.wUoahY/stdout 2025-04-25 19:33:19.990816000 +0000
@@ -1 +1 @@
-? (198.51.100.2) at 02:a9:ae:d3:65:0b on epair0a expires in 1200 seconds [ethernet]
+? (198.51.100.2) at 02:a9:ae:d3:65:0b on epair0a expires in 1199 seconds [ethernet]

Solve this by adding 1 second tolerance

Test Plan

To add load, I’m using a sudo nice -5 stress-ng --matrix 0 -t 10y and running in parallel a : sudo nice -n 19 kyua test sys/netinet/arp:static.
Running in a loop the failure ratio was about 1/10.
With this patch, I didn’t reproduce this problem with 100 loops.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable