From 68a293e75d8882e0a39c79d1805240b7f577f92a Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Sun, 18 Jul 2021 20:33:37 +0200 Subject: [PATCH] Skip wxRegEx tests requiring Unicode support if wxUSE_UNICODE=0 There is not much else that can be done if we can't even represent the contents of the test data properly. --- tests/regex/regextest.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/tests/regex/regextest.cpp b/tests/regex/regextest.cpp index b7cd1b1817..6deb7f89ba 100644 --- a/tests/regex/regextest.cpp +++ b/tests/regex/regextest.cpp @@ -468,6 +468,12 @@ CheckRE( const char *expected, ...) { +#if !wxUSE_UNICODE + // Skip tests requiring Unicode support, we can't do anything else. + if ( *data != '\0' && wxString::FromUTF8(data).empty() ) + return; +#endif // wxUSE_UNICODE + vector expected_results; va_list ap;