aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Gilbert <floppym@gentoo.org>2022-12-31 19:03:34 -0500
committerMike Gilbert <floppym@gentoo.org>2023-01-02 15:35:30 -0500
commit46ae35f6a5aaffff1358dfed369be82569fce786 (patch)
tree4f4b733f3eaff2d3388d8df16b86488306ea694f
parentResolverPlayground: include PATH in env passed to portage.create_trees() (diff)
downloadportage-46ae35f6.tar.gz
portage-46ae35f6.tar.bz2
portage-46ae35f6.zip
egencache: pass through PATH to fix tests with empty profile.env
portage.tests.emerge.test_simple.SimpleEmergeTestCase was failing. /usr/bin/env: 'bash': No such file or directory Signed-off-by: Mike Gilbert <floppym@gentoo.org>
-rwxr-xr-xbin/egencache4
1 files changed, 4 insertions, 0 deletions
diff --git a/bin/egencache b/bin/egencache
index 5f5664131..8c18edaeb 100755
--- a/bin/egencache
+++ b/bin/egencache
@@ -1130,6 +1130,10 @@ try:
# completely controlled by commandline arguments.
env = {}
+ # Pass through PATH to allow testing with an empty profile.env.
+ if "PATH" in os.environ:
+ env["PATH"] = os.environ["PATH"]
+
if not sys.stdout.isatty() or os.environ.get("NOCOLOR", "").lower() in (
"yes",
"true",