diff options
author | Christian Hopps <chopps@labn.net> | 2021-07-27 01:23:20 +0200 |
---|---|---|
committer | Christian Hopps <chopps@labn.net> | 2021-09-04 15:04:46 +0200 |
commit | 4958158787ce9179020d024c14416a23e82713b1 (patch) | |
tree | 8fb926ae2c5d3e267b332464c3e8345fc2ab4e87 /tests/topotests/bgp_evpn_mh | |
parent | tests: NEW micronet replacement for mininet (diff) | |
download | frr-4958158787ce9179020d024c14416a23e82713b1.tar.xz frr-4958158787ce9179020d024c14416a23e82713b1.zip |
tests: micronet: update infra
Signed-off-by: Christian Hopps <chopps@labn.net>
Diffstat (limited to 'tests/topotests/bgp_evpn_mh')
-rw-r--r-- | tests/topotests/bgp_evpn_mh/test_evpn_mh.py | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/tests/topotests/bgp_evpn_mh/test_evpn_mh.py b/tests/topotests/bgp_evpn_mh/test_evpn_mh.py index 2dcf70f14..7c2787d55 100644 --- a/tests/topotests/bgp_evpn_mh/test_evpn_mh.py +++ b/tests/topotests/bgp_evpn_mh/test_evpn_mh.py @@ -30,6 +30,9 @@ test_evpn_mh.py: Testing EVPN multihoming import os import re import sys +import subprocess +from functools import partial + import pytest import json import platform @@ -599,18 +602,20 @@ def test_evpn_ead_update(): def ping_anycast_gw(tgen): # ping the anycast gw from the local and remote hosts to populate # the mac address on the PEs + python3_path = tgen.net.get_exec_path(["python3", "python"]) script_path = os.path.abspath(os.path.join(CWD, "../lib/scapy_sendpkt.py")) intf = "torbond" ipaddr = "45.0.0.1" ping_cmd = [ + python3_path, script_path, "--imports=Ether,ARP", "--interface=" + intf, - "'Ether(dst=\"ff:ff:ff:ff:ff:ff\")/ARP(pdst=\"{}\")'".format(ipaddr) + 'Ether(dst="ff:ff:ff:ff:ff:ff")/ARP(pdst="{}")'.format(ipaddr) ] for name in ("hostd11", "hostd21"): - host = tgen.net[name] - stdout = host.cmd(ping_cmd) + host = tgen.net.hosts[name] + _, stdout, _ = host.cmd_status(ping_cmd, warn=False, stderr=subprocess.STDOUT) stdout = stdout.strip() if stdout: host.logger.debug("%s: arping on %s for %s returned: %s", name, intf, ipaddr, stdout) |