From 7dced311d1119d98dbdd60f6d47fdde5abbff7d7 Mon Sep 17 00:00:00 2001 From: umohnani8 Date: Wed, 16 May 2018 11:41:08 -0400 Subject: Allow push/save without image reference If the user uses the image ID when saving to either docker-archive or oci-archive, then do not save a reference in the manifest/index.json. If the user chooses to push without an image reference, i.e : it should be valid and succeed. Signed-off-by: umohnani8 Closes: #782 Approved by: rhatdan --- test/e2e/push_test.go | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) (limited to 'test') diff --git a/test/e2e/push_test.go b/test/e2e/push_test.go index 46ec4ccbd..b5a1002f2 100644 --- a/test/e2e/push_test.go +++ b/test/e2e/push_test.go @@ -206,4 +206,22 @@ var _ = Describe("Podman push", func() { Expect(clean.ExitCode()).To(Equal(0)) }) + It("podman push to docker-archive no reference", func() { + session := podmanTest.Podman([]string{"push", ALPINE, "docker-archive:/tmp/alp"}) + session.WaitWithDefaultTimeout() + Expect(session.ExitCode()).To(Equal(0)) + clean := podmanTest.SystemExec("rm", []string{"/tmp/alp"}) + clean.WaitWithDefaultTimeout() + Expect(clean.ExitCode()).To(Equal(0)) + }) + + It("podman push to oci-archive no reference", func() { + session := podmanTest.Podman([]string{"push", ALPINE, "oci-archive:/tmp/alp-oci"}) + session.WaitWithDefaultTimeout() + Expect(session.ExitCode()).To(Equal(0)) + clean := podmanTest.SystemExec("rm", []string{"/tmp/alp-oci"}) + clean.WaitWithDefaultTimeout() + Expect(clean.ExitCode()).To(Equal(0)) + }) + }) -- cgit v1.2.3-54-g00ecf