1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24
|
From: Thomas Pierson <contact@thomaspierson.fr>
Date: Sun, 30 Sep 2018 10:57:14 +0200
Subject: fix tests matching because of Qt::ISODate behavior change
Fix some tests results matching because since Qt5.11 milliseconds are now
included in the returned string when calling QTime::toString(Qt::ISODate).
See the Qt bug QTBUG-30250.
---
tests/JsonCreatorTest.cpp | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tests/JsonCreatorTest.cpp b/tests/JsonCreatorTest.cpp
index feb03d5..f2f3dfb 100644
--- a/tests/JsonCreatorTest.cpp
+++ b/tests/JsonCreatorTest.cpp
@@ -100,7 +100,7 @@ void JsonCreatorTest::testSaveSettingsToJSON()
output = JsonCreator::saveSettingsToJSON(set, remove);
QString outString2 = QString::fromLatin1( output ).replace( QLatin1String(" "), QLatin1String("") );
- QString expected2( QLatin1String( "{\"remove\":[\"setting1\",\"setting2\"],\"set\":{\"setting4\":\"stringvalue\",\"setting5\":\"1998-01-01T00:01:02\",\"setting6\":4}}" ) );
+ QString expected2( QLatin1String( "{\"remove\":[\"setting1\",\"setting2\"],\"set\":{\"setting4\":\"stringvalue\",\"setting5\":\"1998-01-01T00:01:02.000\",\"setting6\":4}}" ) );
QCOMPARE( outString2, expected2 );
|