summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorOpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com>2019-07-12 10:33:18 +0200
committerGitHub <noreply@github.com>2019-07-12 10:33:18 +0200
commit6f3e7f7eccdfed03d3d617a9040d5e0b844ea637 (patch)
tree2632afdbee8c1f480ae515453161b65d89866d69 /test
parent20f11718def2a5bf5af96363e9c7082ba48077f4 (diff)
parent369f8b8862e8918a011290311e44c1691f699c58 (diff)
downloadpodman-6f3e7f7eccdfed03d3d617a9040d5e0b844ea637.tar.gz
podman-6f3e7f7eccdfed03d3d617a9040d5e0b844ea637.tar.bz2
podman-6f3e7f7eccdfed03d3d617a9040d5e0b844ea637.zip
Merge pull request #3557 from rhatdan/env
Add support for --env-host
Diffstat (limited to 'test')
-rw-r--r--test/e2e/run_test.go16
1 files changed, 16 insertions, 0 deletions
diff --git a/test/e2e/run_test.go b/test/e2e/run_test.go
index f95c5298d..8c7830204 100644
--- a/test/e2e/run_test.go
+++ b/test/e2e/run_test.go
@@ -226,6 +226,22 @@ var _ = Describe("Podman run", func() {
Expect(match).Should(BeTrue())
})
+ It("podman run --host-env environment test", func() {
+ os.Setenv("FOO", "BAR")
+ session := podmanTest.Podman([]string{"run", "--rm", "--env-host", ALPINE, "printenv", "FOO"})
+ session.WaitWithDefaultTimeout()
+ Expect(session.ExitCode()).To(Equal(0))
+ match, _ := session.GrepString("BAR")
+ Expect(match).Should(BeTrue())
+
+ session = podmanTest.Podman([]string{"run", "--rm", "--env", "FOO=BAR1", "--env-host", ALPINE, "printenv", "FOO"})
+ session.WaitWithDefaultTimeout()
+ Expect(session.ExitCode()).To(Equal(0))
+ match, _ = session.GrepString("BAR1")
+ Expect(match).Should(BeTrue())
+ os.Unsetenv("FOO")
+ })
+
It("podman run limits test", func() {
SkipIfRootless()
session := podmanTest.Podman([]string{"run", "--rm", "--ulimit", "rtprio=99", "--cap-add=sys_nice", fedoraMinimal, "cat", "/proc/self/sched"})