mirror of
https://github.com/containers/podman.git
synced 2025-10-25 02:04:43 +08:00
rmi remove all not error when no images are present
When running podman rm -a on a storage where no images exist, the exit code should NOT be non-zero. Signed-off-by: baude <bbaude@redhat.com> Closes: #1402 Approved by: rhatdan
This commit is contained in:
@ -238,4 +238,14 @@ var _ = Describe("Podman rmi", func() {
|
||||
Expect(session.ExitCode()).To(Equal(0))
|
||||
Expect(len(session.OutputToString())).To(Equal(0))
|
||||
})
|
||||
|
||||
It("podman rmi -a with no images should be exit 0", func() {
|
||||
session := podmanTest.Podman([]string{"rmi", "-fa"})
|
||||
session.WaitWithDefaultTimeout()
|
||||
Expect(session.ExitCode()).To(Equal(0))
|
||||
|
||||
session2 := podmanTest.Podman([]string{"rmi", "-fa"})
|
||||
session2.WaitWithDefaultTimeout()
|
||||
Expect(session2.ExitCode()).To(Equal(0))
|
||||
})
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user