forked from OSchip/llvm-project
[libcxx] [test] XFAIL the get/put long_double_ru_RU tests on Glibc < 2.27
Those older versions used a different monetary decimal separator.
To avoid unnecessary churn to support that, just XFAIL the test
on those older versions. (Up until
df1e43c496
, the whole test was XFAILed
on all versions of glibc.)
Differential Revision: https://reviews.llvm.org/D120979
This commit is contained in:
parent
abe46776f3
commit
9286a8238b
|
@ -11,6 +11,8 @@
|
||||||
|
|
||||||
// REQUIRES: locale.ru_RU.UTF-8
|
// REQUIRES: locale.ru_RU.UTF-8
|
||||||
|
|
||||||
|
// XFAIL: glibc-old-ru_RU-decimal-point
|
||||||
|
|
||||||
// <locale>
|
// <locale>
|
||||||
|
|
||||||
// class money_get<charT, InputIterator>
|
// class money_get<charT, InputIterator>
|
||||||
|
|
|
@ -11,6 +11,8 @@
|
||||||
|
|
||||||
// REQUIRES: locale.ru_RU.UTF-8
|
// REQUIRES: locale.ru_RU.UTF-8
|
||||||
|
|
||||||
|
// XFAIL: glibc-old-ru_RU-decimal-point
|
||||||
|
|
||||||
// <locale>
|
// <locale>
|
||||||
|
|
||||||
// class money_put<charT, OutputIterator>
|
// class money_put<charT, OutputIterator>
|
||||||
|
|
|
@ -105,6 +105,18 @@ DEFAULT_FEATURES = [
|
||||||
}
|
}
|
||||||
""")),
|
""")),
|
||||||
|
|
||||||
|
# Check for Glibc < 2.27, where the ru_RU.UTF-8 locale had
|
||||||
|
# mon_decimal_point == ".", which our tests don't handle.
|
||||||
|
Feature(name='glibc-old-ru_RU-decimal-point',
|
||||||
|
when=lambda cfg: not '_LIBCPP_HAS_NO_LOCALIZATION' in compilerMacros(cfg) and not programSucceeds(cfg, """
|
||||||
|
#include <locale.h>
|
||||||
|
#include <string.h>
|
||||||
|
int main(int, char**) {
|
||||||
|
setlocale(LC_ALL, "ru_RU.UTF-8");
|
||||||
|
return strcmp(localeconv()->mon_decimal_point, ",");
|
||||||
|
}
|
||||||
|
""")),
|
||||||
|
|
||||||
# Whether Bash can run on the executor.
|
# Whether Bash can run on the executor.
|
||||||
# This is not always the case, for example when running on embedded systems.
|
# This is not always the case, for example when running on embedded systems.
|
||||||
#
|
#
|
||||||
|
|
Loading…
Reference in New Issue