mirror of
https://github.com/containers/podman.git
synced 2026-03-31 21:12:11 -04:00
test/e2e: remove image diff test skips
This should work with the latest buildah. Fixes: #26680 Signed-off-by: Paul Holzinger <pholzing@redhat.com>
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
From 814de89af4706b9767b457fd74b9f66f592e7afa Mon Sep 17 00:00:00 2001
|
||||
From 3170dbcf74c62990a288402fb15c7f4f99703144 Mon Sep 17 00:00:00 2001
|
||||
From: Ed Santiago <santiago@redhat.com>
|
||||
Date: Thu, 6 Oct 2022 17:32:59 -0600
|
||||
Subject: [PATCH] tweaks for running buildah tests under podman
|
||||
@@ -6,14 +6,14 @@ Subject: [PATCH] tweaks for running buildah tests under podman
|
||||
Signed-off-by: Ed Santiago <santiago@redhat.com>
|
||||
Signed-off-by: Paul Holzinger <pholzing@redhat.com>
|
||||
---
|
||||
tests/helpers.bash | 113 +++++++++++++++++++++++++++++++++++++++++++--
|
||||
1 file changed, 109 insertions(+), 4 deletions(-)
|
||||
tests/helpers.bash | 158 +++++++++++++++++++++++++++++++++++++++++++--
|
||||
1 file changed, 154 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/tests/helpers.bash b/tests/helpers.bash
|
||||
index 3d1211492..dbf175de3 100644
|
||||
index 9cb1bbc0c..b661fd4ad 100644
|
||||
--- a/tests/helpers.bash
|
||||
+++ b/tests/helpers.bash
|
||||
@@ -82,6 +82,42 @@ EOF
|
||||
@@ -84,6 +84,42 @@ EOF
|
||||
BUILDAH_REGISTRY_OPTS="${regconfopt} ${regconfdir} --short-name-alias-conf ${TEST_SCRATCH_DIR}/cache/shortnames.conf"
|
||||
COPY_REGISTRY_OPTS="${BUILDAH_REGISTRY_OPTS}"
|
||||
PODMAN_REGISTRY_OPTS="${regconfopt}"
|
||||
@@ -56,7 +56,7 @@ index 3d1211492..dbf175de3 100644
|
||||
}
|
||||
|
||||
function starthttpd() { # directory [working-directory-or-"" [certfile, keyfile]]
|
||||
@@ -146,6 +182,22 @@ function teardown_tests() {
|
||||
@@ -148,6 +184,22 @@ function teardown_tests() {
|
||||
stop_git_daemon
|
||||
stop_registry
|
||||
|
||||
@@ -79,7 +79,7 @@ index 3d1211492..dbf175de3 100644
|
||||
# Workaround for #1991 - buildah + overlayfs leaks mount points.
|
||||
# Many tests leave behind /var/tmp/.../root/overlay and sub-mounts;
|
||||
# let's find those and clean them up, otherwise 'rm -rf' fails.
|
||||
@@ -267,7 +319,12 @@ function copy() {
|
||||
@@ -269,7 +321,12 @@ function copy() {
|
||||
}
|
||||
|
||||
function podman() {
|
||||
@@ -93,7 +93,7 @@ index 3d1211492..dbf175de3 100644
|
||||
}
|
||||
|
||||
# There are various scenarios where we would like to execute `tests` as rootless user, however certain commands like `buildah mount`
|
||||
@@ -374,8 +431,78 @@ function run_buildah() {
|
||||
@@ -376,8 +433,78 @@ function run_buildah() {
|
||||
--retry) retry=3; shift;; # retry network flakes
|
||||
esac
|
||||
|
||||
@@ -173,18 +173,18 @@ index 3d1211492..dbf175de3 100644
|
||||
|
||||
# If session is rootless and `buildah mount` is invoked, perform unshare,
|
||||
# since normal user cannot mount a filesystem unless they're in a user namespace along with its own mount namespace.
|
||||
@@ -394,8 +516,8 @@ function run_buildah() {
|
||||
@@ -391,8 +518,8 @@ function run_buildah() {
|
||||
retry=$(( retry - 1 ))
|
||||
|
||||
# stdout is only emitted upon error; this echo is to help a debugger
|
||||
- echo "${_LOG_PROMPT} $BUILDAH_BINARY $*"
|
||||
- echo "${_LOG_PROMPT} ${BUILDAH_BINARY} $*"
|
||||
- run env CONTAINERS_CONF=${CONTAINERS_CONF:-$(dirname ${BASH_SOURCE})/containers.conf} timeout --foreground --kill=10 $BUILDAH_TIMEOUT ${BUILDAH_BINARY} ${BUILDAH_REGISTRY_OPTS} ${ROOTDIR_OPTS} "$@"
|
||||
+ echo "${_LOG_PROMPT} $cmd_basename $*"
|
||||
+ run env CONTAINERS_CONF=${CONTAINERS_CONF:-$(dirname ${BASH_SOURCE})/containers.conf} timeout --foreground --kill=10 $BUILDAH_TIMEOUT ${podman_or_buildah} ${_opts} "$@"
|
||||
# without "quotes", multiple lines are glommed together into one
|
||||
if [ -n "$output" ]; then
|
||||
echo "$output"
|
||||
@@ -422,6 +544,9 @@ function run_buildah() {
|
||||
@@ -419,6 +546,9 @@ function run_buildah() {
|
||||
false
|
||||
fi
|
||||
|
||||
@@ -194,7 +194,7 @@ index 3d1211492..dbf175de3 100644
|
||||
if [ -n "$expected_rc" ]; then
|
||||
if [ "$status" -eq "$expected_rc" ]; then
|
||||
return
|
||||
@@ -759,6 +884,26 @@ function skip_if_no_unshare() {
|
||||
@@ -756,6 +886,26 @@ function skip_if_no_unshare() {
|
||||
fi
|
||||
}
|
||||
|
||||
@@ -222,5 +222,5 @@ index 3d1211492..dbf175de3 100644
|
||||
# start_git_daemon #
|
||||
######################
|
||||
--
|
||||
2.49.0
|
||||
2.50.1
|
||||
|
||||
|
||||
@@ -72,7 +72,6 @@ var _ = Describe("Podman diff", func() {
|
||||
})
|
||||
|
||||
It("podman image diff", func() {
|
||||
Skip("FIXME: #26680 Broken with Buildah v1.41 diff test showing different behavior base on storage driver")
|
||||
file1 := "/" + stringid.GenerateRandomID()
|
||||
file2 := "/" + stringid.GenerateRandomID()
|
||||
file3 := "/" + stringid.GenerateRandomID()
|
||||
@@ -105,7 +104,7 @@ RUN echo test
|
||||
session = podmanTest.Podman([]string{"image", "diff", image, baseImage})
|
||||
session.WaitWithDefaultTimeout()
|
||||
Expect(session).Should(ExitCleanly())
|
||||
Expect(session.OutputToStringArray()).To(HaveLen(4))
|
||||
Expect(session.OutputToStringArray()).To(HaveLen(3))
|
||||
Expect(session.OutputToString()).To(ContainSubstring("A " + file1))
|
||||
Expect(session.OutputToString()).To(ContainSubstring("A " + file2))
|
||||
Expect(session.OutputToString()).To(ContainSubstring("A " + file3))
|
||||
@@ -132,7 +131,6 @@ RUN echo test
|
||||
})
|
||||
|
||||
It("podman diff container and image with same name", func() {
|
||||
Skip("FIXME: #26680 Broken with Buildah v1.41 diff test showing different behavior base on storage driver")
|
||||
imagefile := "/" + stringid.GenerateRandomID()
|
||||
confile := "/" + stringid.GenerateRandomID()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user