Skip to content

Commit

Permalink
e2e: fix pprof flakes
Browse files Browse the repository at this point in the history
Give the services some more time after SIGINT to shutdown.
`Eventually(session, 5)` will poll the session for the specific
condition at a frequency of 10ms for at most 5 seconds.

Fixes: containers#12167
Signed-off-by: Valentin Rothberg <[email protected]>
  • Loading branch information
vrothberg committed Dec 6, 2021
1 parent 188f198 commit 6d7e6d7
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions test/e2e/system_service_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,6 @@ var _ = Describe("podman system service", func() {
defer session.Kill()

WaitForService(address)

session.Wait(5 * time.Second)
Eventually(session, 5).Should(Exit(0))
})
})
Expand Down Expand Up @@ -91,7 +89,7 @@ var _ = Describe("podman system service", func() {
Expect(body).ShouldNot(BeEmpty())

session.Interrupt().Wait(2 * time.Second)
Eventually(session).Should(Exit(1))
Eventually(session, 5).Should(Exit(1))
})

It("are not available", func() {
Expand All @@ -113,7 +111,7 @@ var _ = Describe("podman system service", func() {
Expect(session.Err.Contents()).ShouldNot(ContainSubstring(magicComment))

session.Interrupt().Wait(2 * time.Second)
Eventually(session).Should(Exit(1))
Eventually(session, 5).Should(Exit(1))
})
})
})
Expand Down

0 comments on commit 6d7e6d7

Please sign in to comment.