diff options
author | umohnani8 <umohnani@redhat.com> | 2018-07-03 13:55:59 -0400 |
---|---|---|
committer | Atomic Bot <atomic-devel@projectatomic.io> | 2018-07-05 14:20:12 +0000 |
commit | 33870ea2c3a3aa4e2bd3da3d84b21820c75eaf23 (patch) | |
tree | 76561ded4461593c7da60a70bf891bcc0079a108 /test/e2e/run_test.go | |
parent | 4cc4c7137d29111fe6ccca526bc11d435fa20dd7 (diff) | |
download | podman-33870ea2c3a3aa4e2bd3da3d84b21820c75eaf23.tar.gz podman-33870ea2c3a3aa4e2bd3da3d84b21820c75eaf23.tar.bz2 podman-33870ea2c3a3aa4e2bd3da3d84b21820c75eaf23.zip |
Fix timeout issue with built-in volume test
Building our own image to test built-in volume and user
instead of using the mariadb one.
Solves timeout issue in travis tests.
Signed-off-by: umohnani8 <umohnani@redhat.com>
Closes: #1044
Approved by: mheon
Diffstat (limited to 'test/e2e/run_test.go')
-rw-r--r-- | test/e2e/run_test.go | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/test/e2e/run_test.go b/test/e2e/run_test.go index cb021d297..dc087f700 100644 --- a/test/e2e/run_test.go +++ b/test/e2e/run_test.go @@ -487,11 +487,6 @@ var _ = Describe("Podman run", func() { }) It("podman run with built-in volume image", func() { - travisRun, exists := os.LookupEnv("TRAVIS") - if exists && travisRun == "1" { - Skip("Built-in volume test causes timeouts on Travis - replace mariadb-101-centos7 image to resolve") - } - session := podmanTest.Podman([]string{"run", "--rm", "docker.io/library/redis:alpine", "ls"}) session.WaitWithDefaultTimeout() Expect(session.ExitCode()).To(Equal(0)) @@ -500,12 +495,18 @@ var _ = Describe("Podman run", func() { session.WaitWithDefaultTimeout() Expect(session.ExitCode()).To(Equal(0)) - session = podmanTest.Podman([]string{"run", "--rm", "-e", "MYSQL_USER=zmuser", "-e", "MYSQL_PASSWORD=zmpass", "-e", "MYSQL_DATABASE=zm", "-e", "MYSQL_ROOT_PASSWORD=mysqlpassword", "docker.io/centos/mariadb-101-centos7", "ls", "-al", "/var/lib/mysql/data"}) + dockerfile := `FROM busybox +RUN mkdir -p /myvol/data && chown -R mail.0 /myvol +VOLUME ["/myvol/data"] +USER mail` + + podmanTest.BuildImage(dockerfile, "test", "false") + session = podmanTest.Podman([]string{"run", "--rm", "test", "ls", "-al", "/myvol/data"}) session.WaitWithDefaultTimeout() Expect(session.ExitCode()).To(Equal(0)) - Expect(session.OutputToString()).To(ContainSubstring("mysql root")) + Expect(session.OutputToString()).To(ContainSubstring("mail root")) - session = podmanTest.Podman([]string{"rmi", "docker.io/centos/mariadb-101-centos7"}) + session = podmanTest.Podman([]string{"rmi", "test"}) session.WaitWithDefaultTimeout() Expect(session.ExitCode()).To(Equal(0)) }) |