aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJon Turney <jon.turney@dronecode.org.uk>2018-10-02 13:24:12 +0100
committerJon Turney <jon.turney@dronecode.org.uk>2018-11-04 15:42:06 +0000
commit152ea1a91a151513014a000247c224865cdc14e4 (patch)
tree8cfbb9d71a3b7cff33f3b08a12717848dce51543
parente820c66a4c367397111093bc7531868e2f0ef2e3 (diff)
downloadmeson-152ea1a91a151513014a000247c224865cdc14e4.zip
meson-152ea1a91a151513014a000247c224865cdc14e4.tar.gz
meson-152ea1a91a151513014a000247c224865cdc14e4.tar.bz2
Teach unit test test_compiler_detection about clang-cl
v2: Update for ClangClCcompiler class v3: Reorder compilers to simplify
-rwxr-xr-xrun_unittests.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/run_unittests.py b/run_unittests.py
index 662ca06..adac19b 100755
--- a/run_unittests.py
+++ b/run_unittests.py
@@ -1598,6 +1598,7 @@ class AllPlatformTests(BasePlatformTests):
clang = mesonbuild.compilers.ClangCompiler
intel = mesonbuild.compilers.IntelCompiler
msvc = mesonbuild.compilers.VisualStudioCCompiler
+ clangcl = mesonbuild.compilers.ClangClCCompiler
ar = mesonbuild.linkers.ArLinker
lib = mesonbuild.linkers.VisualStudioLinker
langs = [('c', 'CC'), ('cpp', 'CXX')]
@@ -1619,6 +1620,9 @@ class AllPlatformTests(BasePlatformTests):
if ebase.startswith('g') or ebase.endswith(('-gcc', '-g++')):
self.assertIsInstance(ecc, gnu)
self.assertIsInstance(elinker, ar)
+ elif 'clang-cl' in ebase:
+ self.assertIsInstance(ecc, clangcl)
+ self.assertIsInstance(elinker, lib)
elif 'clang' in ebase:
self.assertIsInstance(ecc, clang)
self.assertIsInstance(elinker, ar)