aboutsummaryrefslogtreecommitdiff
path: root/meson_test.py
diff options
context:
space:
mode:
authorJussi Pakkanen <jpakkane@gmail.com>2015-03-23 23:11:04 +0200
committerJussi Pakkanen <jpakkane@gmail.com>2015-03-23 23:11:04 +0200
commitd289887b1badb079835d0c9734e38150d35e3d15 (patch)
tree8fdaef7edf6bb22c66ece3f11a28d4c97fb64a1d /meson_test.py
parent85132e894860b54c39f29c1491e353a12decc5f6 (diff)
downloadmeson-d289887b1badb079835d0c9734e38150d35e3d15.zip
meson-d289887b1badb079835d0c9734e38150d35e3d15.tar.gz
meson-d289887b1badb079835d0c9734e38150d35e3d15.tar.bz2
Add should_fail kwarg to test to indicate tests that should fail.
Diffstat (limited to 'meson_test.py')
-rwxr-xr-xmeson_test.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/meson_test.py b/meson_test.py
index 533cd87..51a7db6 100755
--- a/meson_test.py
+++ b/meson_test.py
@@ -99,7 +99,8 @@ def run_single_test(wrap, test):
duration = endtime - starttime
stdo = stdo.decode()
stde = stde.decode()
- if p.returncode == 0:
+ if (not test.should_fail and p.returncode == 0) or \
+ (test.should_fail and p.returncode != 0):
res = 'OK'
else:
res = 'FAIL'