aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2017-11-14 13:27:35 -0800
committerZac Medico <zmedico@gentoo.org>2017-11-14 13:31:09 -0800
commit167eda54ae504583dab534522a691aa229c68532 (patch)
tree8eff8303a5fb1a74de4a6d857657d3767a80e64b
parentrepoman/setup.py: create pym -> lib symlink for unit tests (bug 637460) (diff)
downloadportage-167eda54ae504583dab534522a691aa229c68532.tar.gz
portage-167eda54ae504583dab534522a691aa229c68532.tar.bz2
portage-167eda54ae504583dab534522a691aa229c68532.zip
SimpleRepomanTestCase: remove broken PYTHONPATH setting (bug 637460)
Since PORTAGE_PYM_PATH typically refers to the global site-packages directory, using it to set PYTHONPATH is unhelpful. The code involving .repoman_not_installed already overrides sys.path when necessary. Bug: https://bugs.gentoo.org/637460
-rw-r--r--repoman/pym/repoman/tests/simple/test_simple.py15
1 files changed, 0 insertions, 15 deletions
diff --git a/repoman/pym/repoman/tests/simple/test_simple.py b/repoman/pym/repoman/tests/simple/test_simple.py
index 114656eac..a24e0d5a3 100644
--- a/repoman/pym/repoman/tests/simple/test_simple.py
+++ b/repoman/pym/repoman/tests/simple/test_simple.py
@@ -8,7 +8,6 @@ import time
from repoman._portage import portage
from portage import os
from portage import _unicode_decode
-from portage.const import PORTAGE_BASE_PATH, PORTAGE_PYM_PATH
from portage.process import find_binary
from portage.tests.resolver.ResolverPlayground import ResolverPlayground
from portage.util import ensure_dirs
@@ -204,19 +203,6 @@ class SimpleRepomanTestCase(TestCase):
("dev-libs/A", repoman_cmd + ("commit", "-m", "bump to version 4")),
)
- pythonpath = os.environ.get("PYTHONPATH")
- if pythonpath is not None and not pythonpath.strip():
- pythonpath = None
- if pythonpath is not None and \
- pythonpath.split(":")[0] == PORTAGE_PYM_PATH:
- pass
- else:
- if pythonpath is None:
- pythonpath = ""
- else:
- pythonpath = ":" + pythonpath
- pythonpath = PORTAGE_PYM_PATH + pythonpath
-
env = {
"PORTAGE_OVERRIDE_EPREFIX" : eprefix,
"DISTDIR" : distdir,
@@ -228,7 +214,6 @@ class SimpleRepomanTestCase(TestCase):
"PORTAGE_USERNAME" : os.environ["PORTAGE_USERNAME"],
"PORTAGE_REPOSITORIES" : settings.repositories.config_string(),
"PYTHONDONTWRITEBYTECODE" : os.environ.get("PYTHONDONTWRITEBYTECODE", ""),
- "PYTHONPATH" : pythonpath,
}
if os.environ.get("SANDBOX_ON") == "1":