From mboxrd@z Thu Jan 1 00:00:00 1970 From: David Gibson To: passt-dev@passt.top Subject: [PATCH 08/10] test: Use shutdown test for pasta Date: Thu, 18 Aug 2022 16:13:56 +1000 Message-ID: <20220818061358.1775944-9-david@gibson.dropbear.id.au> In-Reply-To: <20220818061358.1775944-1-david@gibson.dropbear.id.au> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="===============5316933629219636022==" --===============5316933629219636022== Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable For the passt and passt_in_ns tests we have a "shutdown" testcase that checks for any errors from the passt process we were using (including valgrind warnings). Do the same for pasta tests, so that we catch any error codes from the pasta process. Signed-off-by: David Gibson --- test/lib/setup | 4 +--- test/run | 1 + test/shutdown/passt | 4 ++-- 3 files changed, 4 insertions(+), 5 deletions(-) diff --git a/test/lib/setup b/test/lib/setup index 19ddd37..450b68a 100755 --- a/test/lib/setup +++ b/test/lib/setup @@ -98,7 +98,7 @@ setup_pasta() { [ ${DEBUG} -eq 1 ] && __opts=3D"${__opts} -d" [ ${TRACE} -eq 1 ] && __opts=3D"${__opts} --trace" =20 - pane_run PASST "./pasta ${__opts} -f -t 10002 -T 10003 -u 10002 -U 10003 ${= __target_pid}" + pane_run PASST "./pasta ${__opts} -f -t 10002 -T 10003 -u 10002 -U 10003 -P= passt.pid ${__target_pid}" sleep 1 } =20 @@ -305,8 +305,6 @@ teardown_passt() { =20 # teardown_passt() - Exit namespace, kill pasta process teardown_pasta() { - tmux send-keys -t ${PANE_PASST} "C-c" - pane_wait PASST tmux send-keys -t ${PANE_NS} "C-d" pane_wait NS } diff --git a/test/run b/test/run index f9792bd..609d91d 100755 --- a/test/run +++ b/test/run @@ -77,6 +77,7 @@ run() { test dhcp/pasta test tcp/pasta test udp/pasta + test shutdown/passt teardown pasta =20 setup passt diff --git a/test/shutdown/passt b/test/shutdown/passt index 00ced61..4a7b702 100644 --- a/test/shutdown/passt +++ b/test/shutdown/passt @@ -6,8 +6,8 @@ # PASTA - Pack A Subtle Tap Abstraction # for network namespace/tap device mode # -# test/shutdown/passt - Shut down passt and check exit code (will detect -# valgrind errors amongst others) +# test/shutdown/passt - Shut down passt (or pasta) and check exit code (will +# detect valgrind errors amongst others) # # Copyright (c) 2022 Red Hat GmbH # Author: Stefano Brivio --=20 2.37.2 --===============5316933629219636022==--