From f72dfdb9afd09ff0d0e0a966d251f8cd56f40968 Mon Sep 17 00:00:00 2001 From: Oliver Wolff Date: Thu, 12 Sep 2019 09:44:48 +0200 Subject: Skip tst_QDateTime::systemTimeZoneChange for UWP configurations Due to their sandboxed nature, UWP applications do not have access to system settings like time zone. Fixes: QTBUG-71185 Change-Id: I567a255f8adc18838fff79b81210faa094674722 Reviewed-by: Edward Welbourne --- tests/auto/corelib/tools/qdatetime/tst_qdatetime.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'tests/auto/corelib') diff --git a/tests/auto/corelib/tools/qdatetime/tst_qdatetime.cpp b/tests/auto/corelib/tools/qdatetime/tst_qdatetime.cpp index ce7cacf966..544eadd3a2 100644 --- a/tests/auto/corelib/tools/qdatetime/tst_qdatetime.cpp +++ b/tests/auto/corelib/tools/qdatetime/tst_qdatetime.cpp @@ -3430,6 +3430,9 @@ void tst_QDateTime::timeZones() const void tst_QDateTime::systemTimeZoneChange() const { +#ifdef Q_OS_WINRT + QSKIP("UWP applications cannot change the system`s time zone (sandboxing)"); +#endif // Set the timezone to Brisbane time TimeZoneRollback useZone(QByteArray("AEST-10:00")); @@ -3447,9 +3450,6 @@ void tst_QDateTime::systemTimeZoneChange() const useZone.reset(QByteArray("IST-05:30")); QCOMPARE(localDate, QDateTime(QDate(2012, 6, 1), QTime(2, 15, 30), Qt::LocalTime)); -#ifdef Q_OS_WINRT - QEXPECT_FAIL("", "WinRT gets this wrong, QTBUG-71185", Continue); -#endif QVERIFY(localMsecs != localDate.toMSecsSinceEpoch()); QCOMPARE(utcDate, QDateTime(QDate(2012, 6, 1), QTime(2, 15, 30), Qt::UTC)); QCOMPARE(utcDate.toMSecsSinceEpoch(), utcMsecs); -- cgit v1.2.3 From 74179a209a8ccdc771b0218f430d5a0519bc619a Mon Sep 17 00:00:00 2001 From: Friedemann Kleint Date: Tue, 24 Sep 2019 09:56:58 +0200 Subject: Revert "BLACKLIST insert_remove_loop for msvc-2019" MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The error was due to a compiler optimization bug, which is fixed in 16.3.0. This reverts commit 305f2c3aa6a2405f8fdeaa33f5d8c684e425f4ee. Fixes: QTBUG-77239 Change-Id: Idfb86ad5c3ec026518f0713c41f7ad744ab4d5db Reviewed-by: MÃ¥rten Nordheim --- tests/auto/corelib/tools/collections/BLACKLIST | 2 -- 1 file changed, 2 deletions(-) delete mode 100644 tests/auto/corelib/tools/collections/BLACKLIST (limited to 'tests/auto/corelib') diff --git a/tests/auto/corelib/tools/collections/BLACKLIST b/tests/auto/corelib/tools/collections/BLACKLIST deleted file mode 100644 index c6e289aadb..0000000000 --- a/tests/auto/corelib/tools/collections/BLACKLIST +++ /dev/null @@ -1,2 +0,0 @@ -[insert_remove_loop] -msvc-2019 -- cgit v1.2.3 From 5839714d986f28412c9f9ed4801d1bf9378f7b51 Mon Sep 17 00:00:00 2001 From: Dmitry Kazakov Date: Thu, 5 Sep 2019 10:23:08 +0300 Subject: Fix QRandomGenerator initialization on AMD CPUs Some AMD CPUs (e.g. AMD A4-6250J and AMD Ryzen 3000-series) have a failing random generation instruction, which always returns 0xffffffff, even when generation was "successful". This code checks if hardware random generator generates four consecutive equal numbers. If it does, then we probably have a failing one and should disable it completely. Change-Id: I38c87920ca2e8cce4143afbff5e453ce3845d11a Fixes: QTBUG-69423 Reviewed-by: Edward Welbourne --- tests/auto/corelib/global/qrandomgenerator/tst_qrandomgenerator.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'tests/auto/corelib') diff --git a/tests/auto/corelib/global/qrandomgenerator/tst_qrandomgenerator.cpp b/tests/auto/corelib/global/qrandomgenerator/tst_qrandomgenerator.cpp index 7c04611823..dca49e9f7e 100644 --- a/tests/auto/corelib/global/qrandomgenerator/tst_qrandomgenerator.cpp +++ b/tests/auto/corelib/global/qrandomgenerator/tst_qrandomgenerator.cpp @@ -320,7 +320,7 @@ void tst_QRandomGenerator::generate32_data() QTest::newRow("fixed") << (RandomValue32 & RandomDataMask); QTest::newRow("global") << 0U; #ifdef QT_BUILD_INTERNAL - if (qt_has_hwrng()) + if (qHasHwrng()) QTest::newRow("hwrng") << uint(UseSystemRNG); QTest::newRow("system") << uint(UseSystemRNG | SkipHWRNG); # ifdef HAVE_FALLBACK_ENGINE @@ -755,7 +755,7 @@ void tst_QRandomGenerator::stdUniformIntDistribution_data() auto newRow = [&](quint32 max) { #ifdef QT_BUILD_INTERNAL - if (qt_has_hwrng()) + if (qHasHwrng()) QTest::addRow("hwrng:%u", max) << uint(UseSystemRNG) << max; QTest::addRow("system:%u", max) << uint(UseSystemRNG | SkipHWRNG) << max; # ifdef HAVE_FALLBACK_ENGINE @@ -868,7 +868,7 @@ void tst_QRandomGenerator::stdUniformRealDistribution_data() auto newRow = [&](double min, double sup) { #ifdef QT_BUILD_INTERNAL - if (qt_has_hwrng()) + if (qHasHwrng()) QTest::addRow("hwrng:%g-%g", min, sup) << uint(UseSystemRNG) << min << sup; QTest::addRow("system:%g-%g", min, sup) << uint(UseSystemRNG | SkipHWRNG) << min << sup; # ifdef HAVE_FALLBACK_ENGINE -- cgit v1.2.3