diff --git a/setup/test.py b/setup/test.py index 6855681be6..6cdf028785 100644 --- a/setup/test.py +++ b/setup/test.py @@ -46,6 +46,8 @@ class Test(Command): sys.libxslt_dylib = ctypes.CDLL(os.path.join(os.environ['SW'], 'lib', 'libxslt.dylib')) sys.libexslt_dylib = ctypes.CDLL(os.path.join(os.environ['SW'], 'lib', 'libexslt.dylib')) print(sys.libxml2_dylib, sys.libxslt_dylib, sys.libexslt_dylib, file=sys.stderr, flush=True) + os.non_calibre_subprocess_env = e = os.environ + del e['DYLD_LIBRARY_PATH'] from calibre.utils.run_tests import ( filter_tests_by_name, remove_tests_by_name, run_cli, find_tests ) diff --git a/src/calibre/srv/tests/auth.py b/src/calibre/srv/tests/auth.py index 94fd56b8e4..e277a34deb 100644 --- a/src/calibre/srv/tests/auth.py +++ b/src/calibre/srv/tests/auth.py @@ -233,7 +233,7 @@ class TestAuth(BaseTest): if curl: def docurl(data, *args): cmd = [curl] + list(args) + ['http://localhost:%d/closed' % server.address[1]] - p = subprocess.Popen(cmd, stdout=subprocess.PIPE, stderr=subprocess.DEVNULL) + p = subprocess.Popen(cmd, stdout=subprocess.PIPE, stderr=subprocess.DEVNULL, env=getattr(os, 'non_calibre_subprocess_env', os.environ)) x = p.stdout.read() p.wait() self.ae(x, data)