aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Mensinger <daniel@mensinger-ka.de>2020-07-17 18:17:47 +0200
committerJussi Pakkanen <jpakkane@gmail.com>2020-07-19 14:45:59 +0300
commit59910c437a81b94c72e3cbdfc2c3612fae576d6e (patch)
tree8f96ba08a9cd6849f77da0ada0797a644c16079b
parent2353d67c25629da049b192d7fddb3e7851edb8df (diff)
downloadmeson-59910c437a81b94c72e3cbdfc2c3612fae576d6e.zip
meson-59910c437a81b94c72e3cbdfc2c3612fae576d6e.tar.gz
meson-59910c437a81b94c72e3cbdfc2c3612fae576d6e.tar.bz2
Fix setuptools 49 test. (fixes #7452)
-rwxr-xr-xrun_meson_command_tests.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/run_meson_command_tests.py b/run_meson_command_tests.py
index 6ed3d8f..7bc6185 100755
--- a/run_meson_command_tests.py
+++ b/run_meson_command_tests.py
@@ -129,6 +129,10 @@ class CommandTests(unittest.TestCase):
os.environ['PYTHONPATH'] = os.path.join(str(pylibdir), '')
os.environ['PATH'] = str(bindir) + os.pathsep + os.environ['PATH']
self._run(python_command + ['setup.py', 'install', '--prefix', str(prefix)])
+ # Fix importlib-metadata by appending all dirs in pylibdir
+ PYTHONPATHS = [pylibdir] + [x for x in pylibdir.iterdir()]
+ PYTHONPATHS = [os.path.join(str(x), '') for x in PYTHONPATHS]
+ os.environ['PYTHONPATH'] = os.pathsep.join(PYTHONPATHS)
# Check that all the files were installed correctly
self.assertTrue(bindir.is_dir())
self.assertTrue(pylibdir.is_dir())