From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from gandalf.ozlabs.org (gandalf.ozlabs.org [150.107.74.76]) by passt.top (Postfix) with ESMTPS id AD08E5A026D for ; Thu, 24 Aug 2023 03:51:02 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gibson.dropbear.id.au; s=201602; t=1692841856; bh=/OzzhuDh2bK+KLSUVMOvl/D5VdGD08NC/mASv95hCec=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=ZnaINdjiwdjClYnepV9U2sO63qzTgDP3fm+d6QteA5H98DGb8lj0x9Zn3dX9NET3L m2/b5wTkCYML44wDlDOcxHkFVQTRM96Ipx0NwCnMVWQB6jUlZ7Re5tSw8b9zZNK/gf ktf9hBvRWaNg2T3jz/Sb0v11Bz5QpZuyPOjUxXeI= Received: by gandalf.ozlabs.org (Postfix, from userid 1007) id 4RWQz44bwmz4wb0; Thu, 24 Aug 2023 11:50:56 +1000 (AEST) Date: Thu, 24 Aug 2023 11:50:06 +1000 From: David Gibson To: Stefano Brivio Subject: Re: [PATCH v2] test: Add Podman system test with bats for pasta Message-ID: References: <20230823135149.2189371-1-sbrivio@redhat.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="7iv/CDERFaJHSfHf" Content-Disposition: inline In-Reply-To: <20230823135149.2189371-1-sbrivio@redhat.com> Message-ID-Hash: XZE57ICDWJW3YFS322I7MTGOSCDSO3RY X-Message-ID-Hash: XZE57ICDWJW3YFS322I7MTGOSCDSO3RY X-MailFrom: dgibson@gandalf.ozlabs.org X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header CC: passt-dev@passt.top, Paul Holzinger X-Mailman-Version: 3.3.8 Precedence: list List-Id: Development discussion and patches for passt Archived-At: Archived-At: List-Archive: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: --7iv/CDERFaJHSfHf Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Aug 23, 2023 at 03:51:49PM +0200, Stefano Brivio wrote: > Ugly as hell, but we keep breaking things otherwise, and I keep > forgetting to run this manually (as long as it's based on my local > Podman setup, that's the only alternative). >=20 > We need to clone the Podman repository as distribution packages don't > contain test scripts, typically. While at it, build the latest > version which is what really matters. >=20 > As we're planning anyway to revamp the test framework, I'd be > inclined to just add this without too many thoughts, and have it as > a nice-to-have requirement reminder for the new framework. >=20 > Link: https://github.com/containers/podman/pull/19699 > Suggested-by: Paul Holzinger > Signed-off-by: Stefano Brivio Clunky, but better than nothing, so Reviewed-by: David Gibson My biggest concern here is that we're unconditionally pulling the latest podman tree. That means that if future podman adds tests for newer pasta features, then checking out an old pasta will get failing tests even for things that were correct at the time of release, which can suck for bisection. > --- > v2: Use CONTAINERS_HELPER_BINARY_DIR to override pasta's path (Paul Holzi= nger) >=20 > test/README.md | 4 ++-- > test/pasta_podman/bats | 21 +++++++++++++++++++++ > test/run | 4 ++++ > 3 files changed, 27 insertions(+), 2 deletions(-) > create mode 100644 test/pasta_podman/bats >=20 > diff --git a/test/README.md b/test/README.md > index 03c7f57..0936b04 100644 > --- a/test/README.md > +++ b/test/README.md > @@ -28,8 +28,8 @@ on a system, i.e. common utilities such as a shell are = not included here. > =20 > Example for Debian, and possibly most Debian-based distributions: > =20 > - build-essential git jq strace iperf3 qemu-system-x86 tmux sipcalc bc > - clang-tidy cppcheck isc-dhcp-common psmisc linux-cpupower socat > + build-essential git jq strace iperf3 qemu-system-x86 tmux sipcalc ba= ts bc > + catatonit clang-tidy cppcheck go isc-dhcp-common psmisc linux-cpupow= er socat > netcat-openbsd fakeroot lz4 lm-sensors qemu-system-arm qemu-system-p= pc > qemu-system-misc qemu-system-x86 valgrind > =20 > diff --git a/test/pasta_podman/bats b/test/pasta_podman/bats > new file mode 100644 > index 0000000..21446f0 > --- /dev/null > +++ b/test/pasta_podman/bats > @@ -0,0 +1,21 @@ > +# SPDX-License-Identifier: GPL-2.0-or-later > +# > +# PASST - Plug A Simple Socket Transport > +# for qemu/UNIX domain socket mode > +# > +# PASTA - Pack A Subtle Tap Abstraction > +# for network namespace/tap device mode > +# > +# test/pasta_podman/bats - Build Podman, run pasta system test with bats > +# > +# Copyright (c) 2022 Red Hat GmbH > +# Author: Stefano Brivio > + > +htools git make go bats catatonit ip jq socat > + > +test Podman system test with bats > + > +host git -C __STATEDIR__ clone https://github.com/containers/podman.git > +host make -C __STATEDIR__/podman > +hout WD pwd > +host PODMAN=3D"__STATEDIR__/podman/bin/podman" CONTAINERS_HELPER_BINARY_= DIR=3D"__WD__" bats __STATEDIR__/podman/test/system/505-networking-pasta.ba= ts > diff --git a/test/run b/test/run > index 8f4f845..3b37663 100755 > --- a/test/run > +++ b/test/run > @@ -82,6 +82,10 @@ run() { > test pasta_options/log_to_file > teardown pasta_options > =20 > + setup build > + test pasta_podman/bats > + teardown build > + > setup memory > test memory/passt > teardown memory --=20 David Gibson | I'll have my music baroque, and my code david AT gibson.dropbear.id.au | minimalist, thank you. NOT _the_ _other_ | _way_ _around_! http://www.ozlabs.org/~dgibson --7iv/CDERFaJHSfHf Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAEBCAAdFiEEO+dNsU4E3yXUXRK2zQJF27ox2GcFAmTmtzEACgkQzQJF27ox 2GdXjw/9GFWZqcZ/UXERRByHhpsaCpRyvt/xar37sTLIB9v0tx+l0Ij46hnbOkuN AfSgirdeNP8aiRPf19py4cDzZ4EHbRbEJO4NH2aYg0hiN6OXyi2G2+15AIr1H923 vkp92D3pAkQ5SNewjM5t/RfGf1CnQtjgCvogzdEecpgsSERRjNSuxXQmMbK0QkFj bwppgMeR57ZndtviOhyBu4OHmA1mGu2rh2mVfcdaTxS7uNiJz8fLCvBCXUdnaHZf fTYypVhdcS0IZiuRI2X82+WkPpkH9qi/mB3EThGVTXYfvuPrTp/Cq9aD1J6uT5Vy QX9akeGY4nNRRNe3KyqDz3SpaJR/xPTpX3fVXTJcTHN4S0WvpuG1GdgSSp1rW2VY tTMubAUecjy8haySohM/AvJ1ylto4vt11Wg2HAByJKF7bdLFudbAiF7ZD2VgINzT mJjDa828OkKh1vXmfqpxHrBQQexl9/3Zlf7Wr+NKUD1M4rVfnJ4wRL8mp/QP7SYM t4TOYNVbKW9tDcoXoLXKCkc4DxS/7JU3DEzeDCqQ/Pit0JT6b9CwMyGVKqpWTdBu SP2ZtcVICC1U9PfLsapTeMDpfqY5YYq9E1O+x38jEPXHELSPSRc4KPGjrgN8s2cP fGcy/CQmo8liaxyZi7x3QH25QKerfdvA7zPv/Ifg0UBHYBUfamU= =e/Fh -----END PGP SIGNATURE----- --7iv/CDERFaJHSfHf--