diff options
author | Dylan Baker <dylan@pnwbakers.com> | 2020-03-24 11:54:00 -0700 |
---|---|---|
committer | Dylan Baker <dylan@pnwbakers.com> | 2020-04-30 10:38:55 -0700 |
commit | 650023f0ccfe2ff8ed8134ab3b26d50c891b0f74 (patch) | |
tree | 8afe57dbea98db7b57e090ca1c7391d08a77e7df /run_unittests.py | |
parent | 90883fa35d48bf4c4b522ba76e3de4f32456a22d (diff) | |
download | meson-650023f0ccfe2ff8ed8134ab3b26d50c891b0f74.zip meson-650023f0ccfe2ff8ed8134ab3b26d50c891b0f74.tar.gz meson-650023f0ccfe2ff8ed8134ab3b26d50c891b0f74.tar.bz2 |
unittests: Add test to show that link_language is broken
Diffstat (limited to 'run_unittests.py')
-rwxr-xr-x | run_unittests.py | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/run_unittests.py b/run_unittests.py index da898a3..35f5f9c 100755 --- a/run_unittests.py +++ b/run_unittests.py @@ -4641,6 +4641,21 @@ recommended as it is not supported on some platforms''') def test_junit_valid_exitcode(self): self._test_junit('44 test args') + def test_link_language_linker(self): + # TODO: there should be some way to query how we're linking things + # without resorting to reading the ninja.build file + if self.backend is not Backend.ninja: + raise unittest.SkipTest('This test reads the ninja file') + + testdir = os.path.join(self.common_test_dir, '230 link language') + self.init(testdir) + + build_ninja = os.path.join(self.builddir, 'build.ninja') + with open(build_ninja, 'r', encoding='utf-8') as f: + contents = f.read() + + self.assertRegex(contents, r'build main(\.exe)?.*: c_LINKER') + class FailureTests(BasePlatformTests): ''' |