From 8bda86faabc5943954d85720967caadc1de95c46 Mon Sep 17 00:00:00 2001 From: Mathieu Duponchelle Date: Sat, 21 Apr 2018 19:07:28 +0200 Subject: python module: make it work with pypy pypy installations don't usuallyy ship with pkg-config files, we thus need to replicate what their version of distutils does. In addition, we also try our best to build against other pythons that do not have pkg-config files. --- run_unittests.py | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'run_unittests.py') diff --git a/run_unittests.py b/run_unittests.py index 834aadb..4c51bb4 100755 --- a/run_unittests.py +++ b/run_unittests.py @@ -3186,6 +3186,19 @@ class PythonTests(BasePlatformTests): self.wipe() + for py in ('pypy', 'pypy3'): + try: + self.init(testdir, ['-Dpython=%s' % py]) + except unittest.SkipTest: + # Same as above, pypy2 and pypy3 are not expected to be present + # on the test system, the test project only raises in these cases + continue + + # We have a pypy, this is expected to work + self.build() + self.run_tests() + self.wipe() + # The test is configured to error out with MESON_SKIP_TEST # in case it could not find python with self.assertRaises(unittest.SkipTest): -- cgit v1.1