blob: fb5d2dc41a170f4eede6f8e9e65f0f05488f8447 [file] [log] [blame]
Alexander Afanasyeva87e0a82014-10-21 14:09:19 -04001#!/usr/bin/env bash
Davide Pesavento2349e282020-03-24 14:28:03 -04002set -ex
Davide Pesavento09348882016-09-17 02:39:44 +02003
Alexander Afanasyeva87e0a82014-10-21 14:09:19 -04004# Prepare environment
Davide Pesavento2349e282020-03-24 14:28:03 -04005rm -rf ~/.ndn
Alexander Afanasyeva87e0a82014-10-21 14:09:19 -04006
Alexander Afanasyevb346ddb2015-06-03 00:52:03 -04007if has OSX $NODE_LABELS; then
Davide Pesavento09348882016-09-17 02:39:44 +02008 security unlock-keychain -p named-data
Alexander Afanasyeva87e0a82014-10-21 14:09:19 -04009fi
10
11ndnsec-keygen "/tmp/jenkins/$NODE_NAME" | ndnsec-install-cert -
12
Davide Pesavento2349e282020-03-24 14:28:03 -040013# https://github.com/google/sanitizers/wiki/AddressSanitizerFlags
Davide Pesavento50e20022016-09-17 18:50:27 +020014ASAN_OPTIONS="color=always"
Davide Pesavento2349e282020-03-24 14:28:03 -040015ASAN_OPTIONS+=":check_initialization_order=1"
16ASAN_OPTIONS+=":detect_stack_use_after_return=1"
17ASAN_OPTIONS+=":strict_init_order=1"
18ASAN_OPTIONS+=":strict_string_checks=1"
19ASAN_OPTIONS+=":detect_invalid_pointer_pairs=2"
Davide Pesavento50e20022016-09-17 18:50:27 +020020ASAN_OPTIONS+=":strip_path_prefix=${PWD}/"
21export ASAN_OPTIONS
22
Davide Pesaventocdb5d8f2018-09-05 22:27:49 -040023export BOOST_TEST_BUILD_INFO=1
24export BOOST_TEST_COLOR_OUTPUT=1
Davide Pesavento78338c52020-04-20 23:00:02 -040025export BOOST_TEST_DETECT_MEMORY_LEAK=0
26export BOOST_TEST_LOGGER=HRF,test_suite,stdout:XML,all,build/xunit-log.xml
Davide Pesaventocdb5d8f2018-09-05 22:27:49 -040027
Alexander Afanasyev667370f2016-08-24 11:54:53 -070028# Run unit tests
Davide Pesavento78338c52020-04-20 23:00:02 -040029./build/unit-tests