mirror of
https://github.com/fmtlib/fmt.git
synced 2024-12-25 15:21:54 +00:00
Skip only strptime dependent test in scan-test
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
This commit is contained in:
parent
69ffedfe52
commit
74c51ff37e
@ -78,11 +78,10 @@ endif()
|
|||||||
add_fmt_test(printf-test)
|
add_fmt_test(printf-test)
|
||||||
add_fmt_test(ranges-test ranges-odr-test.cc)
|
add_fmt_test(ranges-test ranges-odr-test.cc)
|
||||||
|
|
||||||
|
add_fmt_test(scan-test)
|
||||||
check_symbol_exists(strptime "time.h" HAVE_STRPTIME)
|
check_symbol_exists(strptime "time.h" HAVE_STRPTIME)
|
||||||
if (HAVE_STRPTIME)
|
if (HAVE_STRPTIME)
|
||||||
add_fmt_test(scan-test)
|
target_compile_definitions(scan-test PRIVATE FMT_HAVE_STRPTIME)
|
||||||
else()
|
|
||||||
message(WARNING "Skipping scan-test due to missing strptime dependency.")
|
|
||||||
endif ()
|
endif ()
|
||||||
|
|
||||||
add_fmt_test(std-test)
|
add_fmt_test(std-test)
|
||||||
|
@ -65,7 +65,7 @@ TEST(scan_test, read_string_view) {
|
|||||||
EXPECT_EQ(s, "foo");
|
EXPECT_EQ(s, "foo");
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifndef _WIN32
|
#ifdef FMT_HAVE_STRPTIME
|
||||||
namespace fmt {
|
namespace fmt {
|
||||||
template <> struct scanner<tm> {
|
template <> struct scanner<tm> {
|
||||||
std::string format;
|
std::string format;
|
||||||
|
Loading…
Reference in New Issue
Block a user