Merge pull request #21948 from edsantiago/fix-checkpoint-race

e2e: fix potential race in file-locks test
This commit is contained in:
openshift-merge-bot[bot] 2024-03-05 21:10:56 +00:00 committed by GitHub
commit 9c73326e12
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 2 additions and 1 deletions

View File

@ -1449,10 +1449,11 @@ var _ = Describe("Podman checkpoint", func() {
})
It("podman checkpoint and restore container with --file-locks", func() {
localRunString := getRunString([]string{"--name", "test_name", ALPINE, "flock", "test.lock", "sleep", "100"})
localRunString := getRunString([]string{"--name", "test_name", ALPINE, "flock", "test.lock", "sh", "-c", "echo READY;sleep 100"})
session := podmanTest.Podman(localRunString)
session.WaitWithDefaultTimeout()
Expect(session).Should(ExitCleanly())
Expect(WaitContainerReady(podmanTest, "test_name", "READY", 5, 1)).To(BeTrue(), "Timed out waiting for READY")
// Checkpoint is expected to fail without --file-locks
result := podmanTest.Podman([]string{"container", "checkpoint", "test_name"})