diff options
author | Sona Kurazyan <sona.kurazyan@qt.io> | 2021-07-20 11:24:51 +0200 |
---|---|---|
committer | Qt Cherry-pick Bot <cherrypick_bot@qt-project.org> | 2021-07-20 17:15:13 +0000 |
commit | aa78b2037c91cea319bdb761b01c0209c2717217 (patch) | |
tree | b915d6ab793cd244a44f5367d3cde32c10960c36 /tests | |
parent | 160daf5d63efdba507093560816989c55be2e0a2 (diff) |
Skip tst_qthreadonce test on QEMU
The test causes frequent failures in the CI. Couldn't reproduce on
actual arm64 hardware, so it's likely to be a QEMU bug. From the
available logs it seems that all the test cases are flaky (there's a
failure even after cleanupTestCase() is called), so disable all of them.
Fixes: QTBUG-94737
Change-Id: I783ec2179ba779a2c8d93351a78e8472a4f7a907
Reviewed-by: MÃ¥rten Nordheim <marten.nordheim@qt.io>
(cherry picked from commit f3bccd2f4fb583d2f36d41d233c7ad2deb7a7ca2)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Diffstat (limited to 'tests')
-rw-r--r-- | tests/auto/corelib/thread/qthreadonce/CMakeLists.txt | 2 | ||||
-rw-r--r-- | tests/auto/corelib/thread/qthreadonce/tst_qthreadonce.cpp | 9 |
2 files changed, 11 insertions, 0 deletions
diff --git a/tests/auto/corelib/thread/qthreadonce/CMakeLists.txt b/tests/auto/corelib/thread/qthreadonce/CMakeLists.txt index cd4aaa5d72..18ec7723f2 100644 --- a/tests/auto/corelib/thread/qthreadonce/CMakeLists.txt +++ b/tests/auto/corelib/thread/qthreadonce/CMakeLists.txt @@ -8,4 +8,6 @@ qt_internal_add_test(tst_qthreadonce SOURCES qthreadonce.cpp tst_qthreadonce.cpp + LIBRARIES + Qt::TestPrivate ) diff --git a/tests/auto/corelib/thread/qthreadonce/tst_qthreadonce.cpp b/tests/auto/corelib/thread/qthreadonce/tst_qthreadonce.cpp index 7bb39da85c..76b5d87283 100644 --- a/tests/auto/corelib/thread/qthreadonce/tst_qthreadonce.cpp +++ b/tests/auto/corelib/thread/qthreadonce/tst_qthreadonce.cpp @@ -36,11 +36,14 @@ #include <qwaitcondition.h> #include "qthreadonce.h" +#include <QtTest/private/qemulationdetector_p.h> + class tst_QThreadOnce : public QObject { Q_OBJECT private slots: + void initTestCase(); void sameThread(); void sameThread_data(); void multipleThreads(); @@ -52,6 +55,12 @@ private slots: #endif }; +void tst_QThreadOnce::initTestCase() +{ + if (QTestPrivate::isRunningArmOnX86()) + QSKIP("Flaky on QEMU, QTBUG-94737"); +} + class SingletonObject: public QObject { Q_OBJECT |