pespin submitted this change.
testenv: Fix testsuite.run() passing too many envvars to podman
A recent commit added some code in testenv to pass all environment to the
testsuite being run. However, we don't want that happening when running
the testsuite under podman, since then we'd be polluting the env inside
the container with the env from the host running the container.
This fixes running testenv with podman from an Archlinux host having
some TTCN_* extra variables used by testsuite scripts to find ttcn3
binaries & libs under /opt/eclipse-titan/.
Fixes: 95231624f12c299019c0d6064b5d4d3004dad093
Change-Id: Ia8fca37b878323cd188035004b587c124598376e
---
M _testenv/testenv/testsuite.py
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/_testenv/testenv/testsuite.py b/_testenv/testenv/testsuite.py
index 077d3f1..a46d5a9 100644
--- a/_testenv/testenv/testsuite.py
+++ b/_testenv/testenv/testsuite.py
@@ -162,8 +162,10 @@
start_testsuite = os.path.join(ttcn3_hacks_dir, "start-testsuite.sh")
suite = os.path.join(ttcn3_hacks_dir, testenv.args.testsuite, section_data["program"])
- pcap_path = os.path.join(testenv.testdir.testdir, "testsuite")
- env = testenv.cmd.generate_env({ "TTCN3_PCAP_PATH" : pcap_path })
+ env = {
+ "TTCN3_PCAP_PATH": os.path.join(testenv.testdir.testdir, "testsuite"),
+ }
+ env = testenv.cmd.generate_env(env, testenv.args.podman)
cmd = [start_testsuite, suite, section_data["config"]]
To view, visit change 37954. To unsubscribe, or for help writing mail filters, visit settings.