From 1401962a374b2ef8db44a3ef6a2ff2f68564d56f Mon Sep 17 00:00:00 2001 From: Stefano Brivio Date: Fri, 4 Nov 2022 02:08:48 +0100 Subject: test: Wait for network before starting passt in two_guests setup As pasta now configures that target network namespace with --config-net, we need to wait for addresses and routes to be actually present. Just sending netlink messages doesn't mean this is done synchronously. A more elegant alternative, which probably makes sense regardless of this test setup, would be to query, from pasta, addresses and routes we added, and wait until they're there, before proceeding. Signed-off-by: Stefano Brivio --- test/lib/setup | 2 ++ 1 file changed, 2 insertions(+) (limited to 'test/lib') diff --git a/test/lib/setup b/test/lib/setup index ab6d8d5..07d5056 100755 --- a/test/lib/setup +++ b/test/lib/setup @@ -208,6 +208,8 @@ setup_two_guests() { __ifname="$(context_run qemu_1 "ip -j link show | jq -rM '.[] | select(.link_type == \"ether\").ifname'")" + sleep 1 + __opts= [ ${PCAP} -eq 1 ] && __opts="${__opts} -p ${LOGDIR}/passt_1.pcap" [ ${DEBUG} -eq 1 ] && __opts="${__opts} -d" -- cgit v1.2.3