diff options
author | baude <bbaude@redhat.com> | 2018-03-28 09:15:55 -0500 |
---|---|---|
committer | Atomic Bot <atomic-devel@projectatomic.io> | 2018-03-29 16:31:43 +0000 |
commit | 1e59053cc55f82f21442aff6723c89e2af4ddffe (patch) | |
tree | db666eeea2aa844cad151e7004cee72ff48191ff /test/e2e | |
parent | 8a96b4acbc97d5c34ff0160ab1a1b585fdd5d156 (diff) | |
download | podman-1e59053cc55f82f21442aff6723c89e2af4ddffe.tar.gz podman-1e59053cc55f82f21442aff6723c89e2af4ddffe.tar.bz2 podman-1e59053cc55f82f21442aff6723c89e2af4ddffe.zip |
Allow sha256: prefix for input
We should allow users to pass in image ids with the sha256: prefix
for local images.
Resolves: #493
Signed-off-by: baude <bbaude@redhat.com>
Closes: #560
Approved by: baude
Diffstat (limited to 'test/e2e')
-rw-r--r-- | test/e2e/images_test.go | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/test/e2e/images_test.go b/test/e2e/images_test.go index e05281ac9..8b9b889aa 100644 --- a/test/e2e/images_test.go +++ b/test/e2e/images_test.go @@ -3,6 +3,7 @@ package integration import ( "os" + "fmt" . "github.com/onsi/ginkgo" . "github.com/onsi/gomega" ) @@ -129,4 +130,17 @@ var _ = Describe("Podman images", func() { Expect(result.ExitCode()).To(Equal(0)) Expect(len(result.OutputToStringArray())).To(Equal(1)) }) + + It("podman check for image with sha256: prefix", func() { + session := podmanTest.Podman([]string{"inspect", "--format=json", ALPINE}) + session.WaitWithDefaultTimeout() + Expect(session.ExitCode()).To(Equal(0)) + Expect(session.IsJSONOutputValid()).To(BeTrue()) + imageData := session.InspectImageJSON() + + result := podmanTest.Podman([]string{"images", fmt.Sprintf("sha256:%s", imageData[0].ID)}) + result.WaitWithDefaultTimeout() + Expect(result.ExitCode()).To(Equal(0)) + }) + }) |