summaryrefslogtreecommitdiff
path: root/azure-pipelines.yml
diff options
context:
space:
mode:
authorPatrick Steinhardt <ps@pks.im>2019-06-28 13:20:54 +0200
committerPatrick Steinhardt <ps@pks.im>2019-07-20 19:10:10 +0200
commitd827b11b670f3331e5d924eadfe35c497b08035a (patch)
treeb3dc2ce4d2d31cc7f3d1e831b0c02721083dc552 /azure-pipelines.yml
parentfe3b5da3ec9bfbca9f2d17ab6d3eddf39516c9c7 (diff)
downloadlibgit2-d827b11b670f3331e5d924eadfe35c497b08035a.tar.gz
tests: execute leak checker via CTest directly
Right now, we have an awful hack in our test CI setup that extracts the test command from CTest's output and then prepends the leak checker. This is dependent on non-machine-parseable output from CMake and also breaks on various ocassions, like for example when we have spaces in the current path or when the path contains backslashes. Both conditions may easily be triggered on Win32 systems, and in fact they do break our Azure Pipelines builds. Remove the awful hack in favour of a new CMake build option "USE_LEAK_CHECKER". If specifying e.g. "-DUSE_LEAK_CHECKER=valgrind", then we will set up all tests to be run under valgrind. Like this, we can again simply execute ctest without needing to rely on evil sourcery.
Diffstat (limited to 'azure-pipelines.yml')
-rw-r--r--azure-pipelines.yml15
1 files changed, 5 insertions, 10 deletions
diff --git a/azure-pipelines.yml b/azure-pipelines.yml
index 959960f07..0f92df38c 100644
--- a/azure-pipelines.yml
+++ b/azure-pipelines.yml
@@ -16,8 +16,7 @@ jobs:
imageName: 'libgit2/trusty-amd64:latest'
environmentVariables: |
CC=gcc
- CMAKE_OPTIONS=-DUSE_HTTPS=OpenSSL -DREGEX_BACKEND=builtin -DDEPRECATE_HARD=ON
- LEAK_CHECK=valgrind
+ CMAKE_OPTIONS=-DUSE_HTTPS=OpenSSL -DREGEX_BACKEND=builtin -DDEPRECATE_HARD=ON -DUSE_LEAK_CHECKER=valgrind
- job: linux_amd64_trusty_gcc_mbedtls
displayName: 'Linux (amd64; Trusty; GCC; mbedTLS)'
@@ -29,8 +28,7 @@ jobs:
imageName: 'libgit2/trusty-amd64:latest'
environmentVariables: |
CC=gcc
- CMAKE_OPTIONS=-DUSE_HTTPS=mbedTLS -DUSE_SHA1=HTTPS -DDEPRECATE_HARD=ON
- LEAK_CHECK=valgrind
+ CMAKE_OPTIONS=-DUSE_HTTPS=mbedTLS -DUSE_SHA1=HTTPS -DDEPRECATE_HARD=ON -DUSE_LEAK_CHECKER=valgrind
- job: linux_amd64_trusty_clang_openssl
displayName: 'Linux (amd64; Trusty; Clang; OpenSSL)'
@@ -42,8 +40,7 @@ jobs:
imageName: 'libgit2/trusty-amd64:latest'
environmentVariables: |
CC=clang
- CMAKE_OPTIONS=-DUSE_HTTPS=OpenSSL -DDEPRECATE_HARD=ON
- LEAK_CHECK=valgrind
+ CMAKE_OPTIONS=-DUSE_HTTPS=OpenSSL -DDEPRECATE_HARD=ON -DUSE_LEAK_CHECKER=valgrind
- job: linux_amd64_trusty_clang_mbedtls
displayName: 'Linux (amd64; Trusty; Clang; mbedTLS)'
@@ -55,8 +52,7 @@ jobs:
imageName: 'libgit2/trusty-amd64:latest'
environmentVariables: |
CC=clang
- CMAKE_OPTIONS=-DUSE_HTTPS=mbedTLS -DUSE_SHA1=HTTPS -DREGEX_BACKEND=pcre -DDEPRECATE_HARD=ON
- LEAK_CHECK=valgrind
+ CMAKE_OPTIONS=-DUSE_HTTPS=mbedTLS -DUSE_SHA1=HTTPS -DREGEX_BACKEND=pcre -DDEPRECATE_HARD=ON -DUSE_LEAK_CHECKER=valgrind
- job: macos
displayName: 'macOS'
@@ -70,8 +66,7 @@ jobs:
environmentVariables:
TMPDIR: $(Agent.TempDirectory)
PKG_CONFIG_PATH: /usr/local/opt/openssl/lib/pkgconfig
- LEAK_CHECK: leaks
- CMAKE_OPTIONS: -G Ninja -DREGEX_BACKEND=regcomp_l -DDEPRECATE_HARD=ON
+ CMAKE_OPTIONS: -G Ninja -DREGEX_BACKEND=regcomp_l -DDEPRECATE_HARD=ON -DUSE_LEAK_CHECKER=leaks
SKIP_SSH_TESTS: true
- job: windows_vs_amd64