summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--pym/portage/tests/emerge/test_simple.py3
-rw-r--r--pym/portage/tests/repoman/test_simple.py4
2 files changed, 6 insertions, 1 deletions
diff --git a/pym/portage/tests/emerge/test_simple.py b/pym/portage/tests/emerge/test_simple.py
index 5177229ac..a3efa62ca 100644
--- a/pym/portage/tests/emerge/test_simple.py
+++ b/pym/portage/tests/emerge/test_simple.py
@@ -267,7 +267,8 @@ pkg_preinst() {
user_config_dir = os.path.join(os.sep, eprefix, USER_CONFIG_PATH)
features = []
- if not portage.process.sandbox_capable:
+ if not portage.process.sandbox_capable or \
+ os.environ.get("SANDBOX_ON") == "1":
features.append("-sandbox")
# Since egencache ignores settings from the calling environment,
diff --git a/pym/portage/tests/repoman/test_simple.py b/pym/portage/tests/repoman/test_simple.py
index 3643ff2d7..eab06d9b8 100644
--- a/pym/portage/tests/repoman/test_simple.py
+++ b/pym/portage/tests/repoman/test_simple.py
@@ -196,6 +196,10 @@ class SimpleRepomanTestCase(TestCase):
"PYTHONPATH" : pythonpath,
}
+ if os.environ.get("SANDBOX_ON") == "1":
+ # avoid problems from nested sandbox instances
+ env["FEATURES"] = "-sandbox"
+
dirs = [homedir, license_dir, profiles_dir, distdir]
try:
for d in dirs: