mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-07-27 09:43:27 +00:00
isis_srv6_topo1: fix ping does not work as expected
The ping test does not detect when the command fails. > 2025-01-13 15:38:27,494 INFO: topo: [+] check rt1 fc00:0:9::1 0% packet loss > 2025-01-13 15:38:27,494 WARNING: topo: Waiting time is too small (count=10, wait=1), using default values (count=20, wait=3) > 2025-01-13 15:38:28,501 WARNING: rt1: Router(rt1): proc failed: rc 1 pid 2028454 > args: /usr/bin/nsenter --mount=/proc/2026950/ns/mnt --net=/proc/2026950/ns/net --uts=/proc/2026950/ns/uts -F --wd=/tmp/topotests/isis_srv6_topo1.test_isis_srv6_topo1/rt1 /bin/bash -c ping6 fc00:0:9::1 -c 1 -w 1 > stdout: PING fc00:0:9::1(fc00:0:9::1) 56 data bytes > > --- fc00:0:9::1 ping statistics --- > 1 packets transmitted, 0 received, 100% packet loss, time 0ms > stderr: *empty* > 2025-01-13 15:38:28,501 INFO: topo: PING fc00:0:9::1(fc00:0:9::1) 56 data bytes > > --- fc00:0:9::1 ping statistics --- > 1 packets transmitted, 0 received, 100% packet loss, time 0ms > > > PASSED > The match string is not precise enough. Complete it. Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
This commit is contained in:
parent
c6c570a7e6
commit
2610c07831
@ -245,7 +245,7 @@ def check_ping6(name, dest_addr, expect_connected):
|
||||
if match not in output:
|
||||
return "ping fail"
|
||||
|
||||
match = "{} packet loss".format("0%" if expect_connected else "100%")
|
||||
match = "{} packet loss".format(", 0%" if expect_connected else ", 100%")
|
||||
logger.info("[+] check {} {} {}".format(name, dest_addr, match))
|
||||
tgen = get_topogen()
|
||||
func = functools.partial(_check, name, dest_addr, match)
|
||||
|
Loading…
Reference in New Issue
Block a user