mirror of
https://github.com/fmtlib/fmt.git
synced 2026-02-15 22:59:57 +08:00
Check if setlocale succeeded
(cherry picked from commit 5b106083e79b0f6c2f3850fa1c0ac0a69b81e595)
This commit is contained in:
parent
ae8ae747bd
commit
affac0bea0
@ -1214,8 +1214,8 @@ TEST(FormatterTest, FormatIntLocale) {
|
|||||||
#else
|
#else
|
||||||
const char *locale = "English_United States";
|
const char *locale = "English_United States";
|
||||||
#endif
|
#endif
|
||||||
std::setlocale(LC_ALL, locale);
|
if (std::setlocale(LC_ALL, locale))
|
||||||
EXPECT_EQ("1,234,567", format("{:n}", 1234567));
|
EXPECT_EQ("1,234,567", format("{:n}", 1234567));
|
||||||
}
|
}
|
||||||
|
|
||||||
TEST(FormatterTest, FormatFloat) {
|
TEST(FormatterTest, FormatFloat) {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user