diff options
Diffstat (limited to 'test/e2e')
-rw-r--r-- | test/e2e/create_test.go | 30 | ||||
-rw-r--r-- | test/e2e/run_device_test.go | 5 | ||||
-rw-r--r-- | test/e2e/system_service_test.go | 2 |
3 files changed, 37 insertions, 0 deletions
diff --git a/test/e2e/create_test.go b/test/e2e/create_test.go index 6a4a394ef..339fa66d8 100644 --- a/test/e2e/create_test.go +++ b/test/e2e/create_test.go @@ -706,4 +706,34 @@ var _ = Describe("Podman create", func() { Expect(create.ErrorToString()).To(ContainSubstring("cannot specify a new uid/gid map when entering a pod with an infra container")) }) + + It("podman create --chrootdirs inspection test", func() { + session := podmanTest.Podman([]string{"create", "--chrootdirs", "/var/local/qwerty", ALPINE}) + session.WaitWithDefaultTimeout() + Expect(session).Should(Exit(0)) + + setup := podmanTest.Podman([]string{"container", "inspect", session.OutputToString()}) + setup.WaitWithDefaultTimeout() + Expect(setup).Should(Exit(0)) + + data := setup.InspectContainerToJSON() + Expect(data).To(HaveLen(1)) + Expect(data[0].Config.ChrootDirs).To(HaveLen(1)) + Expect(data[0].Config.ChrootDirs[0]).To(Equal("/var/local/qwerty")) + }) + + It("podman create --chrootdirs functionality test", func() { + session := podmanTest.Podman([]string{"create", "-t", "--chrootdirs", "/var/local/qwerty", ALPINE, "/bin/cat"}) + session.WaitWithDefaultTimeout() + Expect(session).Should(Exit(0)) + ctrID := session.OutputToString() + + setup := podmanTest.Podman([]string{"start", ctrID}) + setup.WaitWithDefaultTimeout() + Expect(setup).Should(Exit(0)) + + setup = podmanTest.Podman([]string{"exec", ctrID, "cmp", "/etc/resolv.conf", "/var/local/qwerty/etc/resolv.conf"}) + setup.WaitWithDefaultTimeout() + Expect(setup).Should(Exit(0)) + }) }) diff --git a/test/e2e/run_device_test.go b/test/e2e/run_device_test.go index b8bdc84f8..479837dda 100644 --- a/test/e2e/run_device_test.go +++ b/test/e2e/run_device_test.go @@ -44,6 +44,11 @@ var _ = Describe("Podman run device", func() { session := podmanTest.Podman([]string{"run", "-q", "--security-opt", "label=disable", "--device", "/dev/kmsg", ALPINE, "test", "-c", "/dev/kmsg"}) session.WaitWithDefaultTimeout() Expect(session).Should(Exit(0)) + if !isRootless() { + session = podmanTest.Podman([]string{"run", "-q", "--security-opt", "label=disable", "--device", "/dev/kmsg", "--cap-add", "SYS_ADMIN", ALPINE, "head", "-n", "1", "/dev/kmsg"}) + session.WaitWithDefaultTimeout() + Expect(session).Should(Exit(0)) + } }) It("podman run device rename test", func() { diff --git a/test/e2e/system_service_test.go b/test/e2e/system_service_test.go index dcf5e03b2..2bc7756d6 100644 --- a/test/e2e/system_service_test.go +++ b/test/e2e/system_service_test.go @@ -58,6 +58,7 @@ var _ = Describe("podman system service", func() { const magicComment = "pprof service listening on" It("are available", func() { + Skip("FIXME: Test is too flaky (#12624)") SkipIfRemote("service subcommand not supported remotely") address := url.URL{ @@ -97,6 +98,7 @@ var _ = Describe("podman system service", func() { }) It("are not available", func() { + Skip("FIXME: Test is too flaky (#12624)") SkipIfRemote("service subcommand not supported remotely") address := url.URL{ |