Skip to content

Use functor-based singleShot() overload in TestJob::start()

Igor Kushnir requested to merge fix-kjobtest-failure-qt5.12 into master

KJobTest::testEmitAtMostOnce() depends on the order of slot/lambda invocations being the same as the order of QTimer::singleShot() calls. This is always the case since Qt 5.14.0 thanks to qtbase commit 58b4e0736919e0504f5ca5307ad7aefa894a6f38. But the order is not always the same in earlier Qt versions when different QTimer::singleShot() overloads are used. When KJobTest's TestJob::start() calls the string-based singleShot() overload and KJobTest::testEmitAtMostOnce() calls the functor-based overload, KJobTest::testEmitAtMostOnce() fails with Qt 5.12.

Merge request reports