📌 use JSON test data v1.0.0

This commit is contained in:
Niels Lohmann 2020-05-04 16:00:00 +02:00
parent e7a88b2d7f
commit 2304629a3f
No known key found for this signature in database
GPG key ID: 7F3CEA63AE251B69

View file

@ -1,9 +1,12 @@
find_package(Git) find_package(Git)
set(JSON_TEST_DATA_URL https://github.com/nlohmann/json_test_data)
set(JSON_TEST_DATA_VERSION 1.0.0)
# target to download test data # target to download test data
add_custom_target(download_test_data add_custom_target(download_test_data
COMMAND test -d json_test_data || ${GIT_EXECUTABLE} clone https://github.com/nlohmann/json_test_data.git --quiet --depth 1 COMMAND test -d json_test_data || ${GIT_EXECUTABLE} clone -c advice.detachedHead=false --branch v${JSON_TEST_DATA_VERSION} ${JSON_TEST_DATA_URL}.git --quiet --depth 1
COMMENT "Downloading test data from https://github.com/nlohmann/json_test_data" COMMENT "Downloading test data from ${JSON_TEST_DATA_URL} (v${JSON_TEST_DATA_VERSION})"
WORKING_DIRECTORY ${CMAKE_BINARY_DIR} WORKING_DIRECTORY ${CMAKE_BINARY_DIR}
) )