aboutsummaryrefslogtreecommitdiff
path: root/ci
diff options
context:
space:
mode:
authorHennadii Stepanov <32963518+hebasto@users.noreply.github.com>2022-01-02 12:01:32 +0200
committerHennadii Stepanov <32963518+hebasto@users.noreply.github.com>2022-01-06 16:23:48 +0200
commit0b7c55f157514e1845934fff3f9c66e862c526ca (patch)
treedb73fb261bb615d09f4d167cc4ceab744491e96b /ci
parent8b5a4de904b414fb3a818732cd0a2c90b91bc275 (diff)
downloadbitcoin-0b7c55f157514e1845934fff3f9c66e862c526ca.tar.xz
ci: Clone entire bitcoin-core/qa-assets repo only when run fuzzing
Diffstat (limited to 'ci')
-rwxr-xr-xci/test/04_install.sh12
1 files changed, 8 insertions, 4 deletions
diff --git a/ci/test/04_install.sh b/ci/test/04_install.sh
index 308d216562..491a587b70 100755
--- a/ci/test/04_install.sh
+++ b/ci/test/04_install.sh
@@ -87,13 +87,17 @@ fi
DOCKER_EXEC echo "Free disk space:"
DOCKER_EXEC df -h
-if [ "$RUN_FUZZ_TESTS" = "true" ] || [ "$RUN_UNIT_TESTS" = "true" ] || [ "$RUN_UNIT_TESTS_SEQUENTIAL" = "true" ]; then
- if [ ! -d "${DIR_QA_ASSETS}" ]; then
+if [ "$RUN_FUZZ_TESTS" = "true" ]; then
+ export DIR_FUZZ_IN=${DIR_QA_ASSETS}/fuzz_seed_corpus/
+ if [ ! -d "$DIR_FUZZ_IN" ]; then
DOCKER_EXEC git clone --depth=1 https://github.com/bitcoin-core/qa-assets "${DIR_QA_ASSETS}"
fi
-
- export DIR_FUZZ_IN=${DIR_QA_ASSETS}/fuzz_seed_corpus/
+elif [ "$RUN_UNIT_TESTS" = "true" ] || [ "$RUN_UNIT_TESTS_SEQUENTIAL" = "true" ]; then
export DIR_UNIT_TEST_DATA=${DIR_QA_ASSETS}/unit_test_data/
+ if [ ! -d "$DIR_UNIT_TEST_DATA" ]; then
+ DOCKER_EXEC mkdir -p "$DIR_UNIT_TEST_DATA"
+ DOCKER_EXEC curl --location --fail https://github.com/bitcoin-core/qa-assets/raw/main/unit_test_data/script_assets_test.json -o "${DIR_UNIT_TEST_DATA}/script_assets_test.json"
+ fi
fi
DOCKER_EXEC mkdir -p "${BASE_SCRATCH_DIR}/sanitizer-output/"