summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJon Turney <jon.turney@dronecode.org.uk>2018-10-07 13:12:49 +0100
committerJon Turney <jon.turney@dronecode.org.uk>2018-10-14 16:01:36 +0100
commit459b81de4644106fabd410870f577848bef99fe6 (patch)
tree9227651e8d39c92b9330a6493e938f0334de5eb3
parent7bdb39668bd2efd579d94e7d69a0b429e026499b (diff)
downloadmeson-459b81de4644106fabd410870f577848bef99fe6.tar.gz
Use 'CI' environment variable to detect CI environment
Use the 'CI' environment variable to detect CI environment, rather than a collection of CI-specific ones.
-rwxr-xr-xrun_cross_test.py2
-rwxr-xr-xrun_project_tests.py2
-rwxr-xr-xrun_tests.py2
-rwxr-xr-xrun_unittests.py8
-rw-r--r--test cases/frameworks/17 mpi/meson.build2
5 files changed, 8 insertions, 8 deletions
diff --git a/run_cross_test.py b/run_cross_test.py
index 71914028f..2b640ec86 100755
--- a/run_cross_test.py
+++ b/run_cross_test.py
@@ -38,7 +38,7 @@ def runtests(cross_file):
print('\nTotal passed cross tests:', passing_tests)
print('Total failed cross tests:', failing_tests)
print('Total skipped cross tests:', skipped_tests)
- if failing_tests > 0 and ('TRAVIS' in os.environ or 'APPVEYOR' in os.environ):
+ if failing_tests > 0 and ('CI' in os.environ):
print('\nMesonlogs of failing tests\n')
for l in failing_logs:
print(l, '\n')
diff --git a/run_project_tests.py b/run_project_tests.py
index 876d1359a..a9c7eca7a 100755
--- a/run_project_tests.py
+++ b/run_project_tests.py
@@ -81,7 +81,7 @@ class AutoDeletedDir:
failing_logs = []
print_debug = 'MESON_PRINT_TEST_OUTPUT' in os.environ
-under_ci = not {'TRAVIS', 'APPVEYOR'}.isdisjoint(os.environ)
+under_ci = 'CI' in os.environ
do_debug = under_ci or print_debug
no_meson_log_msg = 'No meson-log.txt found.'
diff --git a/run_tests.py b/run_tests.py
index af926eab3..242338825 100755
--- a/run_tests.py
+++ b/run_tests.py
@@ -245,7 +245,7 @@ if __name__ == '__main__':
elif arg == '--cross=arm':
cross = 'arm'
# Running on a developer machine? Be nice!
- if not mesonlib.is_windows() and not mesonlib.is_haiku() and 'TRAVIS' not in os.environ:
+ if not mesonlib.is_windows() and not mesonlib.is_haiku() and 'CI' not in os.environ:
os.nice(20)
# Appveyor sets the `platform` environment variable which completely messes
# up building with the vs2010 and vs2015 backends.
diff --git a/run_unittests.py b/run_unittests.py
index 9ffce52f4..e02bc6c51 100755
--- a/run_unittests.py
+++ b/run_unittests.py
@@ -81,7 +81,7 @@ def is_tarball():
return False
def is_ci():
- if 'TRAVIS' in os.environ or 'APPVEYOR' in os.environ:
+ if 'CI' in os.environ:
return True
return False
@@ -98,8 +98,8 @@ def _git_init(project_dir):
def skipIfNoPkgconfig(f):
'''
- Skip this test if no pkg-config is found, unless we're on Travis or
- Appveyor CI. This allows users to run our test suite without having
+ Skip this test if no pkg-config is found, unless we're on CI.
+ This allows users to run our test suite without having
pkg-config installed on, f.ex., macOS, while ensuring that our CI does not
silently skip the test because of misconfiguration.
@@ -1671,7 +1671,7 @@ class AllPlatformTests(BasePlatformTests):
self.assertIsInstance(linker, lib)
self.assertEqual(cc.id, 'msvc')
self.assertTrue(hasattr(cc, 'is_64'))
- # If we're in the appveyor CI, we know what the compiler will be
+ # If we're on Windows CI, we know what the compiler will be
if 'arch' in os.environ:
if os.environ['arch'] == 'x64':
self.assertTrue(cc.is_64)
diff --git a/test cases/frameworks/17 mpi/meson.build b/test cases/frameworks/17 mpi/meson.build
index 1085d40c8..b2f9fb853 100644
--- a/test cases/frameworks/17 mpi/meson.build
+++ b/test cases/frameworks/17 mpi/meson.build
@@ -17,7 +17,7 @@ exec = executable('exec',
test('MPI C', exec)
if build_machine.system() != 'windows'
- # C++ MPI not supported by MS-MPI used on AppVeyor.
+ # C++ MPI not supported by MS-MPI
mpicpp = dependency('mpi', language : 'cpp')
execpp = executable('execpp',
'main.cpp',