aboutsummaryrefslogtreecommitdiff
path: root/unittests
diff options
context:
space:
mode:
authorEli Schwartz <eschwartz@archlinux.org>2022-02-15 23:26:44 -0500
committerEli Schwartz <eschwartz@archlinux.org>2022-02-17 14:48:27 -0500
commita580fac83abd56a7576ea81f7cbb4693dffdcfe0 (patch)
tree6c424c9e05bf556498b92531dd406da8f5d71e47 /unittests
parented262cad97daa9d00fe44a39fd04dfa4eb763d7b (diff)
downloadmeson-a580fac83abd56a7576ea81f7cbb4693dffdcfe0.zip
meson-a580fac83abd56a7576ea81f7cbb4693dffdcfe0.tar.gz
meson-a580fac83abd56a7576ea81f7cbb4693dffdcfe0.tar.bz2
tests: allow setting MESON_CI_JOBNAME=thirdparty
This is treated by the test harness as though unset, i.e. we do normal skipping and don't assume we are running in Meson's own project CI. However, it has one distinction which is that it isn't an error to set $CI without setting $MESON_CI_JOBNAME, if it is in fact set but to the ignored value. This lets automated workflows such as Linux distro testing, particularly alpine linux, set $CI or have it set for them by default, without messing things up. Also it has the advantage of $CI actually enabling useful benefits! We will still assume that this thirdparty environment wants to force verbose logging (printing testlogs, running ninja/samu with -v) and colorize the console.
Diffstat (limited to 'unittests')
-rw-r--r--unittests/helpers.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/unittests/helpers.py b/unittests/helpers.py
index 0945384..182dfa3 100644
--- a/unittests/helpers.py
+++ b/unittests/helpers.py
@@ -17,7 +17,7 @@ from run_tests import get_fake_env
def is_ci():
- if 'MESON_CI_JOBNAME' in os.environ:
+ if os.environ.get('MESON_CI_JOBNAME') not in {None, 'thirdparty'}:
return True
return False