fix: unittests sets locale before testing

the convert_with_stringstream seems to be missing a
.imbue() call to set the locale independent of the global state.
Not setting this, can in some settings lead to errors, see Issue #1366.
This commit is contained in:
Simon Gene Gottlieb
2025-12-10 03:47:08 +01:00
committed by Jesse Beder
parent bbf8bdb087
commit a2826e8983

View File

@@ -10,6 +10,7 @@ namespace {
template <typename T>
static std::string convert_with_stringstream(T v, size_t precision = 0) {
std::stringstream ss;
ss.imbue(std::locale::classic());
if (precision > 0) {
ss << std::setprecision(precision);
}