diff options
author | Daniel J Walsh <dwalsh@redhat.com> | 2022-07-26 06:41:08 -0400 |
---|---|---|
committer | Daniel J Walsh <dwalsh@redhat.com> | 2022-07-26 16:00:42 -0400 |
commit | 75419c5d887e23f93a465311b02bb76d8cea1940 (patch) | |
tree | 1bce4f62fd40b7996561d608db8613b6db22fc77 /test/system/200-pod.bats | |
parent | 242639f4b1689231c37f909d3bda58b774a0ea96 (diff) | |
download | podman-75419c5d887e23f93a465311b02bb76d8cea1940.tar.gz podman-75419c5d887e23f93a465311b02bb76d8cea1940.tar.bz2 podman-75419c5d887e23f93a465311b02bb76d8cea1940.zip |
When removing objects specifying --force,podman should exit with 0
This Patch will cause podman COMMAND rm --force bogus not fail
This is how Docker works, so Podman should follow this to allow existing
scripts to convert from Docker to Podman.
Fixes: #14612
Oprignal version of this patch came from wufan 1991849113@qq.com
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
Diffstat (limited to 'test/system/200-pod.bats')
-rw-r--r-- | test/system/200-pod.bats | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/test/system/200-pod.bats b/test/system/200-pod.bats index 667e2baef..da2f7cd59 100644 --- a/test/system/200-pod.bats +++ b/test/system/200-pod.bats @@ -547,4 +547,11 @@ io.max | $lomajmin rbps=1048576 wbps=1048576 riops=max wiops=max wait } +@test "podman pod rm --force bogus" { + run_podman 1 pod rm bogus + is "$output" "Error: .*bogus.*: no such pod" "Should print error" + run_podman pod rm --force bogus + is "$output" "" "Should print no output" +} + # vim: filetype=sh |