From e288c3a7ee352a71a810ca3c798834321e18db26 Mon Sep 17 00:00:00 2001 From: Roman Telezhynskyi Date: Wed, 6 Sep 2017 13:22:57 +0300 Subject: [PATCH] Fix test. Ensure that we also remove a thousands separator in test. (grafted from 023f2d495cf49a2cf8dc58b3154aed42e57882a9) --HG-- branch : develop --- src/test/ValentinaTest/tst_vtranslatevars.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/test/ValentinaTest/tst_vtranslatevars.cpp b/src/test/ValentinaTest/tst_vtranslatevars.cpp index f62492f3f..d02c6950b 100644 --- a/src/test/ValentinaTest/tst_vtranslatevars.cpp +++ b/src/test/ValentinaTest/tst_vtranslatevars.cpp @@ -145,7 +145,11 @@ void TST_VTranslateVars::PrepareValFromUser(double d, const QLocale &locale) void TST_VTranslateVars::PrepareValToUser(double d, const QLocale &locale) { const QString formulaFromSystem = QLocale::c().toString(d); - const QString formulaToUser = locale.toString(d); + QString formulaToUser = locale.toString(d); + if (locale.groupSeparator().isSpace()) + { + formulaToUser.replace(locale.groupSeparator(), ""); + } PrepareVal(formulaFromSystem, formulaToUser, locale); }