aboutsummaryrefslogtreecommitdiff
path: root/test/e2e/system_reset_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'test/e2e/system_reset_test.go')
-rw-r--r--test/e2e/system_reset_test.go20
1 files changed, 16 insertions, 4 deletions
diff --git a/test/e2e/system_reset_test.go b/test/e2e/system_reset_test.go
index 641f98c38..c0739303f 100644
--- a/test/e2e/system_reset_test.go
+++ b/test/e2e/system_reset_test.go
@@ -35,9 +35,15 @@ var _ = Describe("podman system reset", func() {
})
It("podman system reset", func() {
+ Skip("Disabled until Netavark testing added")
SkipIfRemote("system reset not supported on podman --remote")
// system reset will not remove additional store images, so need to grab length
+ // change the network dir so that we do not conflict with other tests
+ // that would use the same network dir and cause unnecessary flakes
+ // TODO: Uncomment when we enable Netavark testing in E2E.
+ //podmanTest.NetworkConfigDir = tempdir
+
session := podmanTest.Podman([]string{"rmi", "--force", "--all"})
session.WaitWithDefaultTimeout()
Expect(session).Should(Exit(0))
@@ -56,16 +62,16 @@ var _ = Describe("podman system reset", func() {
session.WaitWithDefaultTimeout()
Expect(session).Should(Exit(0))
+ session = podmanTest.Podman([]string{"network", "create"})
+ session.WaitWithDefaultTimeout()
+ Expect(session).Should(Exit(0))
+
session = podmanTest.Podman([]string{"system", "reset", "-f"})
session.WaitWithDefaultTimeout()
Expect(session).Should(Exit(0))
Expect(session.ErrorToString()).To(Not(ContainSubstring("Failed to add pause process")))
- // If remote then the API service should have exited
- // On local tests this is a noop
- podmanTest.StartRemoteService()
-
session = podmanTest.Podman([]string{"images", "-n"})
session.WaitWithDefaultTimeout()
Expect(session).Should(Exit(0))
@@ -80,5 +86,11 @@ var _ = Describe("podman system reset", func() {
session.WaitWithDefaultTimeout()
Expect(session).Should(Exit(0))
Expect(session.OutputToStringArray()).To(BeEmpty())
+
+ session = podmanTest.Podman([]string{"network", "ls", "-q"})
+ session.WaitWithDefaultTimeout()
+ Expect(session).Should(Exit(0))
+ // default network should exists
+ Expect(session.OutputToStringArray()).To(HaveLen(1))
})
})