diff options
author | Giuseppe Scrivano <gscrivan@redhat.com> | 2020-04-09 09:56:26 +0200 |
---|---|---|
committer | Giuseppe Scrivano <gscrivan@redhat.com> | 2020-04-09 10:17:42 +0200 |
commit | d3cfa7a23c2343581185b8ddf9bab6f2ccf9eccc (patch) | |
tree | e30b6b865dc0f729ebb46cda232cd7dca0c80280 /test/e2e/libpod_suite_test.go | |
parent | 291ad7fbd9797340015b71b448c6637669176878 (diff) | |
download | podman-d3cfa7a23c2343581185b8ddf9bab6f2ccf9eccc.tar.gz podman-d3cfa7a23c2343581185b8ddf9bab6f2ccf9eccc.tar.bz2 podman-d3cfa7a23c2343581185b8ddf9bab6f2ccf9eccc.zip |
test: fix exec preserve-fds test
it specifies a fd is passed down but we are not really doing it, and
it triggers the wrong fd to be closed by Podman after the OCI runtime
invocation.
Closes: https://github.com/containers/libpod/issues/5769
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
Diffstat (limited to 'test/e2e/libpod_suite_test.go')
-rw-r--r-- | test/e2e/libpod_suite_test.go | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/test/e2e/libpod_suite_test.go b/test/e2e/libpod_suite_test.go index dc5e91c72..29a55980c 100644 --- a/test/e2e/libpod_suite_test.go +++ b/test/e2e/libpod_suite_test.go @@ -27,6 +27,12 @@ func (p *PodmanTestIntegration) Podman(args []string) *PodmanSessionIntegration return &PodmanSessionIntegration{podmanSession} } +// PodmanExtraFiles is the exec call to podman on the filesystem and passes down extra files +func (p *PodmanTestIntegration) PodmanExtraFiles(args []string, extraFiles []*os.File) *PodmanSessionIntegration { + podmanSession := p.PodmanAsUserBase(args, 0, 0, "", nil, false, false, extraFiles) + return &PodmanSessionIntegration{podmanSession} +} + // PodmanNoCache calls the podman command with no configured imagecache func (p *PodmanTestIntegration) PodmanNoCache(args []string) *PodmanSessionIntegration { podmanSession := p.PodmanBase(args, false, true) @@ -42,7 +48,7 @@ func (p *PodmanTestIntegration) PodmanNoEvents(args []string) *PodmanSessionInte // PodmanAsUser is the exec call to podman on the filesystem with the specified uid/gid and environment func (p *PodmanTestIntegration) PodmanAsUser(args []string, uid, gid uint32, cwd string, env []string) *PodmanSessionIntegration { - podmanSession := p.PodmanAsUserBase(args, uid, gid, cwd, env, false, false) + podmanSession := p.PodmanAsUserBase(args, uid, gid, cwd, env, false, false, nil) return &PodmanSessionIntegration{podmanSession} } |