rootless tests using stop is more reliable

when testing rootless containers, it is more reliable to stop
a container with a zero timeout than kill a container.  We made
this change in non-rootless tests as well.  When IO or CPU are
taxed, it avoids a situation where the kill signal is sent but the
container has not been able to update its status when a subsequent
action occurs.

Signed-off-by: baude <bbaude@redhat.com>
This commit is contained in:
baude
2018-12-23 11:47:46 -06:00
parent eb982193c5
commit df923b2613

View File

@ -210,7 +210,7 @@ var _ = Describe("Podman rootless", func() {
cmd.WaitWithDefaultTimeout()
Expect(cmd.ExitCode()).To(Equal(0))
cmd = rootlessTest.PodmanAsUser([]string{"kill", "-l"}, 1000, 1000, env)
cmd = rootlessTest.PodmanAsUser([]string{"stop", "-l", "-t", "0"}, 1000, 1000, env)
cmd.WaitWithDefaultTimeout()
Expect(cmd.ExitCode()).To(Equal(0))