summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorOpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com>2021-09-02 10:27:16 -0400
committerGitHub <noreply@github.com>2021-09-02 10:27:16 -0400
commit469900406ac51332785455bc8668bd1c053badd6 (patch)
tree7eb39b91c2b9e235cda5298d604c517244c0836e /test
parentafa9987f876b08647e419e798a738f0f98e47600 (diff)
parentcba114dd3617b7f793fa43817058d40505f4d454 (diff)
downloadpodman-469900406ac51332785455bc8668bd1c053badd6.tar.gz
podman-469900406ac51332785455bc8668bd1c053badd6.tar.bz2
podman-469900406ac51332785455bc8668bd1c053badd6.zip
Merge pull request #11406 from flouthoc/manifest-rm-only-manifest
manifest: `rm` should not remove referenced images.
Diffstat (limited to 'test')
-rw-r--r--test/e2e/manifest_test.go28
1 files changed, 28 insertions, 0 deletions
diff --git a/test/e2e/manifest_test.go b/test/e2e/manifest_test.go
index 95f90d4c1..27aaaba48 100644
--- a/test/e2e/manifest_test.go
+++ b/test/e2e/manifest_test.go
@@ -280,4 +280,32 @@ var _ = Describe("Podman manifest", func() {
session.WaitWithDefaultTimeout()
Expect(session).Should(Exit(1))
})
+
+ It("podman manifest rm should not remove referenced images", func() {
+ manifestList := "manifestlist"
+ imageName := "quay.io/libpod/busybox"
+
+ session := podmanTest.Podman([]string{"pull", imageName})
+ session.WaitWithDefaultTimeout()
+ Expect(session).Should(Exit(0))
+
+ session = podmanTest.Podman([]string{"manifest", "create", manifestList})
+ session.WaitWithDefaultTimeout()
+ Expect(session).Should(Exit(0))
+
+ session = podmanTest.Podman([]string{"manifest", "add", manifestList, imageName})
+ session.WaitWithDefaultTimeout()
+ Expect(session).Should(Exit(0))
+
+ session = podmanTest.Podman([]string{"manifest", "rm", manifestList})
+ session.WaitWithDefaultTimeout()
+ Expect(session).Should(Exit(0))
+
+ //image should still show up
+ session = podmanTest.Podman([]string{"images"})
+ session.WaitWithDefaultTimeout()
+ Expect(session.OutputToString()).To(ContainSubstring(imageName))
+ Expect(session).Should(Exit(0))
+ })
+
})