Skip to content

Commit 80951fc

Browse files
jvijtiukmichalvasko
authored andcommitted
travis FEATURE add sanitizer test job
1 parent b647aa1 commit 80951fc

1 file changed

Lines changed: 14 additions & 5 deletions

File tree

.travis.yml

Lines changed: 14 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,12 +6,20 @@ matrix:
66
dist: trusty
77
sudo: required
88
compiler: clang
9+
env: SANITIZE="OFF"
10+
- os: linux
11+
dist: trusty
12+
sudo: required
13+
compiler: clang
14+
env: SANITIZE="ON"
915
- os: linux
1016
dist: trusty
1117
sudo: required
1218
compiler: gcc
19+
env: SANITIZE="OFF"
1320
- os: osx
1421
compiler: gcc
22+
env: SANITIZE="OFF"
1523
allow_failures:
1624
- os: osx
1725

@@ -28,11 +36,12 @@ before_install:
2836

2937
script:
3038
- if [ "$TRAVIS_OS_NAME" = "osx" ]; then export OPENSSLFLAGS="-DOPENSSL_ROOT_DIR=/usr/local/opt/openssl"; fi
31-
- cd $TRAVIS_BUILD_DIR && mkdir build_none && cd build_none ; cmake -DENABLE_TLS=OFF -DENABLE_SSH=OFF -DENABLE_DNSSEC=OFF .. && make -j2 && ctest --output-on-failure
32-
- cd $TRAVIS_BUILD_DIR && mkdir build_tls && cd build_tls ; cmake $OPENSSLFLAGS -DENABLE_TLS=ON -DENABLE_SSH=OFF -DENABLE_DNSSEC=OFF .. && make -j2 && ctest --output-on-failure
33-
- cd $TRAVIS_BUILD_DIR && mkdir build_ssh && cd build_ssh ; cmake $OPENSSLFLAGS -DENABLE_TLS=OFF -DENABLE_SSH=ON -DENABLE_DNSSEC=OFF .. && make -j2 && ctest --output-on-failure
34-
- cd $TRAVIS_BUILD_DIR && mkdir build_ssh_tls && cd build_ssh_tls ; cmake $OPENSSLFLAGS -DENABLE_TLS=ON -DENABLE_SSH=ON -DENABLE_DNSSEC=OFF .. && make -j2 && ctest --output-on-failure
35-
- cd $TRAVIS_BUILD_DIR && mkdir build_all && cd build_all ; cmake $OPENSSLFLAGS -DENABLE_TLS=ON -DENABLE_SSH=ON -DENABLE_DNSSEC=ON .. && make -j2 && ctest --output-on-failure
39+
- if [ "$SANITIZE" = "ON" ]; then export SANITIZEFLAGS='-DCMAKE_C_FLAGS="-fsanitize=address,undefined" -DENABLE_VALGRIND_TESTS=OFF'; fi
40+
- cd $TRAVIS_BUILD_DIR && mkdir build_none && cd build_none ; cmake -DENABLE_TLS=OFF -DENABLE_SSH=OFF -DENABLE_DNSSEC=OFF $SANITIZEFLAGS .. && make -j2 && ctest --output-on-failure
41+
- cd $TRAVIS_BUILD_DIR && mkdir build_tls && cd build_tls ; cmake $OPENSSLFLAGS -DENABLE_TLS=ON -DENABLE_SSH=OFF -DENABLE_DNSSEC=OFF $SANITIZEFLAGS .. && make -j2 && ctest --output-on-failure
42+
- cd $TRAVIS_BUILD_DIR && mkdir build_ssh && cd build_ssh ; cmake $OPENSSLFLAGS -DENABLE_TLS=OFF -DENABLE_SSH=ON -DENABLE_DNSSEC=OFF $SANITIZEFLAGS .. && make -j2 && ctest --output-on-failure
43+
- cd $TRAVIS_BUILD_DIR && mkdir build_ssh_tls && cd build_ssh_tls ; cmake $OPENSSLFLAGS -DENABLE_TLS=ON -DENABLE_SSH=ON -DENABLE_DNSSEC=OFF $SANITIZEFLAGS .. && make -j2 && ctest --output-on-failure
44+
- cd $TRAVIS_BUILD_DIR && mkdir build_all && cd build_all ; cmake $OPENSSLFLAGS -DENABLE_TLS=ON -DENABLE_SSH=ON -DENABLE_DNSSEC=ON $SANITIZEFLAGS .. && make -j2 && ctest --output-on-failure
3645
- cd -
3746

3847
after_success:

0 commit comments

Comments
 (0)