|
@@ -28,11 +28,11 @@ FetchContent_MakeAvailable(json_schema_test_suite)
|
|
|
include(GoogleTest)
|
|
include(GoogleTest)
|
|
|
|
|
|
|
|
add_executable(annotation_test annotation_test.cxx)
|
|
add_executable(annotation_test annotation_test.cxx)
|
|
|
-target_link_libraries(annotation_test GTest::gtest GTest::gmock ada-idna jsoncpp_lib)
|
|
|
|
|
|
|
+target_link_libraries(annotation_test GTest::gtest GTest::gmock jsoncpp_lib)
|
|
|
gtest_discover_tests(annotation_test)
|
|
gtest_discover_tests(annotation_test)
|
|
|
|
|
|
|
|
add_executable(extension_test extension_test.cxx)
|
|
add_executable(extension_test extension_test.cxx)
|
|
|
-target_link_libraries(extension_test GTest::gtest GTest::gmock ada-idna jsoncpp_lib)
|
|
|
|
|
|
|
+target_link_libraries(extension_test GTest::gtest GTest::gmock jsoncpp_lib)
|
|
|
gtest_discover_tests(extension_test)
|
|
gtest_discover_tests(extension_test)
|
|
|
|
|
|
|
|
add_executable(selfvalidate_test selfvalidate_test.cxx)
|
|
add_executable(selfvalidate_test selfvalidate_test.cxx)
|
|
@@ -43,14 +43,16 @@ target_compile_definitions(selfvalidate_test
|
|
|
JVALIDATE_JSON_SCHEMA_TEST_SUITE_DIR="${json_schema_test_suite_SOURCE_DIR}"
|
|
JVALIDATE_JSON_SCHEMA_TEST_SUITE_DIR="${json_schema_test_suite_SOURCE_DIR}"
|
|
|
)
|
|
)
|
|
|
endif()
|
|
endif()
|
|
|
-target_link_libraries(selfvalidate_test GTest::gtest GTest::gmock ada-idna jsoncpp_lib CURL::libcurl)
|
|
|
|
|
|
|
+target_link_libraries(selfvalidate_test GTest::gtest GTest::gmock jsoncpp_lib CURL::libcurl)
|
|
|
|
|
|
|
|
if (ICU_FOUND)
|
|
if (ICU_FOUND)
|
|
|
- target_link_libraries(annotation_test ICU::uc ICU::i18n)
|
|
|
|
|
- target_link_libraries(extension_test ICU::uc ICU::i18n)
|
|
|
|
|
target_link_libraries(selfvalidate_test ICU::uc ICU::i18n)
|
|
target_link_libraries(selfvalidate_test ICU::uc ICU::i18n)
|
|
|
endif()
|
|
endif()
|
|
|
|
|
|
|
|
|
|
+if (IDNA_POPULATED)
|
|
|
|
|
+ target_link_libraries(selfvalidate_test ada-idna)
|
|
|
|
|
+endif()
|
|
|
|
|
+
|
|
|
string(
|
|
string(
|
|
|
JOIN ":"
|
|
JOIN ":"
|
|
|
SelfValidateTest_Unsupported
|
|
SelfValidateTest_Unsupported
|
|
@@ -58,16 +60,37 @@ string(
|
|
|
"*optional_*ecmascript_regex"
|
|
"*optional_*ecmascript_regex"
|
|
|
"*optional_zeroTerminatedFloats"
|
|
"*optional_zeroTerminatedFloats"
|
|
|
)
|
|
)
|
|
|
|
|
+
|
|
|
if (NOT ${ICU_FOUND})
|
|
if (NOT ${ICU_FOUND})
|
|
|
string(
|
|
string(
|
|
|
- JOIN ":"
|
|
|
|
|
- SelfValidateTest_Unsupported
|
|
|
|
|
- ${SelfValidateTest_Unsupported}
|
|
|
|
|
- "*optional_non_bmp_regex"
|
|
|
|
|
|
|
+ APPEND SelfValidateTest_Unsupported
|
|
|
|
|
+ ":*optional_non_bmp_regex"
|
|
|
)
|
|
)
|
|
|
endif()
|
|
endif()
|
|
|
|
|
+
|
|
|
|
|
+set(SelfValidateTest_Unsupported_Suites "")
|
|
|
set(SelfValidateTest_Unsupported_Cases "*leap second")
|
|
set(SelfValidateTest_Unsupported_Cases "*leap second")
|
|
|
|
|
|
|
|
|
|
+if (NOT ${IDNA_POPULATED})
|
|
|
|
|
+ string(
|
|
|
|
|
+ APPEND SelfValidateTest_Unsupported
|
|
|
|
|
+ ":*optional_*iri*"
|
|
|
|
|
+ ":*optional_*idn*"
|
|
|
|
|
+ ":*optional_*uri_template*"
|
|
|
|
|
+ )
|
|
|
|
|
+ string(
|
|
|
|
|
+ APPEND SelfValidateTest_Unsupported_Suites
|
|
|
|
|
+ ":*punycode*"
|
|
|
|
|
+ ":*puny-code"
|
|
|
|
|
+ )
|
|
|
|
|
+ string(
|
|
|
|
|
+ APPEND SelfValidateTest_Unsupported_Cases
|
|
|
|
|
+ ":*punycode*"
|
|
|
|
|
+ ":*puny-code"
|
|
|
|
|
+ )
|
|
|
|
|
+endif()
|
|
|
|
|
+
|
|
|
gtest_discover_tests(selfvalidate_test
|
|
gtest_discover_tests(selfvalidate_test
|
|
|
- EXTRA_ARGS --json_case_filter=-${SelfValidateTest_Unsupported_Cases}
|
|
|
|
|
|
|
+ EXTRA_ARGS --json_suite_filter=-${SelfValidateTest_Unsupported_Suites}
|
|
|
|
|
+ --json_case_filter=-${SelfValidateTest_Unsupported_Cases}
|
|
|
TEST_FILTER -${SelfValidateTest_Unsupported})
|
|
TEST_FILTER -${SelfValidateTest_Unsupported})
|