aboutsummaryrefslogtreecommitdiff
path: root/run_unittests.py
diff options
context:
space:
mode:
authorJussi Pakkanen <jpakkane@gmail.com>2018-01-03 22:32:40 +0200
committerGitHub <noreply@github.com>2018-01-03 22:32:40 +0200
commit65f78a722ad0f8ab260e7cf24636ef38e8bd957f (patch)
tree76024acbc0c7d90e8edd69ad07c79124de622a46 /run_unittests.py
parentc814f1145bc521efd0a46b033751a6f844d24df5 (diff)
parentbcc95d7dd703779228ec81b92197e010d0e5a1ea (diff)
downloadmeson-65f78a722ad0f8ab260e7cf24636ef38e8bd957f.zip
meson-65f78a722ad0f8ab260e7cf24636ef38e8bd957f.tar.gz
meson-65f78a722ad0f8ab260e7cf24636ef38e8bd957f.tar.bz2
Merge pull request #2856 from jon-turney/warning-location
Consolidate warning location formatting
Diffstat (limited to 'run_unittests.py')
-rwxr-xr-xrun_unittests.py14
1 files changed, 10 insertions, 4 deletions
diff --git a/run_unittests.py b/run_unittests.py
index e5011c3..dae72a8 100755
--- a/run_unittests.py
+++ b/run_unittests.py
@@ -1710,10 +1710,16 @@ int main(int argc, char **argv) {
def test_warning_location(self):
tdir = os.path.join(self.unit_test_dir, '20 warning location')
out = self.init(tdir)
- self.assertRegex(out, r'WARNING: Keyword argument "link_with" defined multiple times in file meson.build, line 4')
- self.assertRegex(out, r'WARNING: Keyword argument "link_with" defined multiple times in file sub' + re.escape(os.path.sep) + r'meson.build, line 3')
- self.assertRegex(out, r'WARNING: a warning of some sort in file meson.build, line 6')
- self.assertRegex(out, r'WARNING: subdir warning in file sub' + re.escape(os.path.sep) + r'meson.build, line 4')
+ for expected in [
+ r'WARNING: Keyword argument "link_with" defined multiple times in file meson.build, line 4',
+ r'WARNING: Keyword argument "link_with" defined multiple times in file sub' + os.path.sep + r'meson.build, line 3',
+ r'WARNING: a warning of some sort in file meson.build, line 6',
+ r'WARNING: subdir warning in file sub' + os.path.sep + r'meson.build, line 4',
+ r'WARNING: Module unstable-simd has no backwards or forwards compatibility and might not exist in future releases in file meson.build, line 7',
+ r"WARNING: The variable(s) 'MISSING' in the input file conf.in are not present in the given configuration data in file meson.build, line 10",
+ r'WARNING: Passed invalid keyword argument "invalid" in file meson.build, line 1'
+ ]:
+ self.assertRegex(out, re.escape(expected))
def test_templates(self):
ninja = detect_ninja()