👷 added flags for Valgrind and Clang sanitizer

This commit is contained in:
Niels Lohmann 2017-08-25 20:12:21 +02:00
parent c87b080cc5
commit 05b97c473a
No known key found for this signature in database
GPG key ID: 7F3CEA63AE251B69
2 changed files with 29 additions and 10 deletions

View file

@ -29,34 +29,28 @@ matrix:
include:
# Valgrind
- os: linux
compiler: gcc
env:
- COMPILER=g++-4.9
- SPECIAL=valgrind
- CMAKE_OPTIONS=-DJSON_Valgrind=ON
addons:
apt:
sources: ['ubuntu-toolchain-r-test']
packages: [g++-4.9, valgrind]
after_success:
- make check TEST_PREFIX="valgrind --error-exitcode=1 --leak-check=full " TEST_PATTERN=""
# clang sanitizer
- os: linux
compiler: clang
env:
- COMPILER=clang++-5.0
- SPECIAL=sanitizer
- CMAKE_OPTIONS=-DJSON_Sanitizer=ON
addons:
apt:
sources: ['ubuntu-toolchain-r-test', 'llvm-toolchain-trusty-5.0']
packages: ['g++-6', 'clang-5.0']
after_success:
- make clang_sanitize -j4
# cppcheck
- os: linux
compiler: gcc
env:
@ -289,7 +283,7 @@ script:
# compile and execute unit tests
- mkdir -p build && cd build
- cmake .. && cmake --build . --config Release -- -j4
- cmake .. ${CMAKE_OPTIONS} && cmake --build . --config Release -- -j4
- ctest -C Release -V
- cd ..