podman exec CID without command should exit 125

Fixes: https://github.com/containers/podman/issues/22329

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
This commit is contained in:
Daniel J Walsh
2024-04-11 11:08:55 -04:00
parent 7b95a8af80
commit 5e68fbd132
3 changed files with 8 additions and 5 deletions

View File

@ -32,11 +32,7 @@ var _ = Describe("Podman exec", func() {
// With no command
session = podmanTest.Podman([]string{"exec", "test1"})
session.WaitWithDefaultTimeout()
expectedStatus := 255
if IsRemote() {
expectedStatus = 125
}
Expect(session).Should(ExitWithError(expectedStatus, "must provide a non-empty command to start an exec session: invalid argument"))
Expect(session).Should(ExitWithError(125, "must provide a non-empty command to start an exec session: invalid argument"))
})
It("podman container exec simple command", func() {