diff options
author | Jussi Pakkanen <jpakkane@gmail.com> | 2018-02-27 20:29:25 +0200 |
---|---|---|
committer | Jussi Pakkanen <jpakkane@gmail.com> | 2018-03-04 14:56:40 +0200 |
commit | c209b2f45d6c37c7d3f2334bce657202cb56ea73 (patch) | |
tree | da7a4f5c5d82622b98ccea23c978f472dd47caf4 | |
parent | ea3b54d40252fcb87eb1852223f125398b1edbdf (diff) | |
download | meson-fixexternalbin.tar.gz |
Skip test that requires mocking when using an external exe. Also logging.fixexternalbin
-rwxr-xr-x | run_unittests.py | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/run_unittests.py b/run_unittests.py index 41cbf3931..b87981baa 100755 --- a/run_unittests.py +++ b/run_unittests.py @@ -526,9 +526,13 @@ class BasePlatformTests(unittest.TestCase): self.privatedir = os.path.join(self.builddir, 'meson-private') if inprocess: try: - (returncode, out, _) = run_configure(self.meson_mainfile, self.meson_args + args + extra_args) + (returncode, out, err) = run_configure(self.meson_mainfile, self.meson_args + args + extra_args) if returncode != 0: self._print_meson_log() + print('Stdout:\n') + print(out) + print('Stderr:\n') + print(err) raise RuntimeError('Configure failed') except: self._print_meson_log() @@ -1749,6 +1753,11 @@ int main(int argc, char **argv) { self._run(ninja, workdir=os.path.join(tmpdir, 'builddir')) + # The test uses mocking and thus requires that + # the current process is the one to run the Meson steps. + # If we are using an external test executable (most commonly + # in Debian autopkgtests) then the mocking won't work. + @unittest.skipIf('MESON_EXE' in os.environ, 'MESON_EXE is defined, can not use mocking.') def test_cross_file_system_paths(self): if is_windows(): raise unittest.SkipTest('system crossfile paths not defined for Windows (yet)') |