Ashlesh Gawande | 0b2897e | 2018-06-20 14:40:47 -0500 | [diff] [blame] | 1 | #!/usr/bin/env bash |
Davide Pesavento | 133067f | 2020-04-02 22:08:27 -0400 | [diff] [blame] | 2 | set -ex |
Ashlesh Gawande | 0b2897e | 2018-06-20 14:40:47 -0500 | [diff] [blame] | 3 | |
| 4 | # Prepare environment |
Davide Pesavento | 133067f | 2020-04-02 22:08:27 -0400 | [diff] [blame] | 5 | rm -rf ~/.ndn |
Ashlesh Gawande | 0b2897e | 2018-06-20 14:40:47 -0500 | [diff] [blame] | 6 | ndnsec-keygen "/tmp/jenkins/$NODE_NAME" | ndnsec-install-cert - |
| 7 | |
Davide Pesavento | 133067f | 2020-04-02 22:08:27 -0400 | [diff] [blame] | 8 | # https://github.com/google/sanitizers/wiki/AddressSanitizerFlags |
Ashlesh Gawande | 0b2897e | 2018-06-20 14:40:47 -0500 | [diff] [blame] | 9 | ASAN_OPTIONS="color=always" |
Davide Pesavento | 133067f | 2020-04-02 22:08:27 -0400 | [diff] [blame] | 10 | ASAN_OPTIONS+=":check_initialization_order=1" |
| 11 | ASAN_OPTIONS+=":detect_stack_use_after_return=1" |
| 12 | ASAN_OPTIONS+=":strict_init_order=1" |
| 13 | ASAN_OPTIONS+=":strict_string_checks=1" |
| 14 | ASAN_OPTIONS+=":detect_invalid_pointer_pairs=2" |
Ashlesh Gawande | 0b2897e | 2018-06-20 14:40:47 -0500 | [diff] [blame] | 15 | ASAN_OPTIONS+=":strip_path_prefix=${PWD}/" |
| 16 | export ASAN_OPTIONS |
| 17 | |
Davide Pesavento | 1526fee | 2019-03-18 19:31:55 -0400 | [diff] [blame] | 18 | export BOOST_TEST_BUILD_INFO=1 |
| 19 | export BOOST_TEST_COLOR_OUTPUT=1 |
Davide Pesavento | 042dfb3 | 2020-07-23 21:07:16 -0400 | [diff] [blame] | 20 | export BOOST_TEST_DETECT_MEMORY_LEAK=0 |
| 21 | export BOOST_TEST_LOGGER=HRF,test_suite,stdout:XML,all,build/xunit-log.xml |
Ashlesh Gawande | 0b2897e | 2018-06-20 14:40:47 -0500 | [diff] [blame] | 22 | |
| 23 | # Run unit tests |
Davide Pesavento | 042dfb3 | 2020-07-23 21:07:16 -0400 | [diff] [blame] | 24 | ./build/unit-tests |