2019-01-31 16:28:02 -05:00
|
|
|
#!/usr/bin/env bash
|
|
|
|
#
|
2019-12-30 22:39:22 +13:00
|
|
|
# Copyright (c) 2018-2019 The Bitcoin Core developers
|
2019-01-31 16:28:02 -05:00
|
|
|
# Distributed under the MIT software license, see the accompanying
|
|
|
|
# file COPYING or http://www.opensource.org/licenses/mit-license.php.
|
|
|
|
|
|
|
|
export LC_ALL=C.UTF-8
|
|
|
|
|
2019-10-02 17:10:57 -04:00
|
|
|
if [ -n "$QEMU_USER_CMD" ]; then
|
|
|
|
BEGIN_FOLD wrap-qemu
|
|
|
|
# Generate all binaries, so that they can be wrapped
|
|
|
|
DOCKER_EXEC make $MAKEJOBS -C src/secp256k1 VERBOSE=1
|
|
|
|
DOCKER_EXEC make $MAKEJOBS -C src/univalue VERBOSE=1
|
2019-12-17 13:33:58 -05:00
|
|
|
DOCKER_EXEC "${BASE_ROOT_DIR}/ci/test/wrap-qemu.sh"
|
2019-10-02 17:10:57 -04:00
|
|
|
END_FOLD
|
|
|
|
fi
|
|
|
|
|
2019-11-15 11:38:27 -05:00
|
|
|
if [ -n "$USE_VALGRIND" ]; then
|
|
|
|
BEGIN_FOLD wrap-valgrind
|
|
|
|
DOCKER_EXEC "${BASE_ROOT_DIR}/ci/test/wrap-valgrind.sh"
|
|
|
|
END_FOLD
|
|
|
|
fi
|
|
|
|
|
2019-01-31 16:28:02 -05:00
|
|
|
if [ "$RUN_UNIT_TESTS" = "true" ]; then
|
|
|
|
BEGIN_FOLD unit-tests
|
2019-11-04 13:54:05 -05:00
|
|
|
bash -c "${CI_WAIT}" & # Print dots in case the unit tests take a long time to run
|
2019-11-20 19:40:22 -05:00
|
|
|
DOCKER_EXEC LD_LIBRARY_PATH=$DEPENDS_DIR/$HOST/lib make $MAKEJOBS check VERBOSE=1
|
2019-01-31 16:28:02 -05:00
|
|
|
END_FOLD
|
|
|
|
fi
|
|
|
|
|
|
|
|
if [ "$RUN_FUNCTIONAL_TESTS" = "true" ]; then
|
|
|
|
BEGIN_FOLD functional-tests
|
2019-08-27 15:53:02 -04:00
|
|
|
DOCKER_EXEC test/functional/test_runner.py --ci $MAKEJOBS --tmpdirprefix "${BASE_SCRATCH_DIR}/test_runner/" --ansi --combinedlogslen=4000 ${TEST_RUNNER_EXTRA} --quiet --failfast
|
2019-01-31 16:28:02 -05:00
|
|
|
END_FOLD
|
|
|
|
fi
|
2019-01-16 11:49:01 -05:00
|
|
|
|
|
|
|
if [ "$RUN_FUZZ_TESTS" = "true" ]; then
|
|
|
|
BEGIN_FOLD fuzz-tests
|
2020-02-17 13:34:51 +00:00
|
|
|
DOCKER_EXEC test/fuzz/test_runner.py ${FUZZ_TESTS_CONFIG} -l DEBUG ${DIR_FUZZ_IN}
|
2019-01-16 11:49:01 -05:00
|
|
|
END_FOLD
|
|
|
|
fi
|