Remove superfluous call from qWaitFor
The remaining time will be fetched again after checking the predicate, so the read value was never used. Change-Id: I627152116ea579577e490ecefbaee02fec4aabdc Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
This commit is contained in:
parent
087f26f9da
commit
a344758640
@ -74,10 +74,8 @@ namespace QTest
|
||||
QCoreApplication::sendPostedEvents(nullptr, QEvent::DeferredDelete);
|
||||
|
||||
remaining = deadline.remainingTime();
|
||||
if (remaining > 0) {
|
||||
if (remaining > 0)
|
||||
QTest::qSleep(qMin(10, remaining));
|
||||
remaining = deadline.remainingTime();
|
||||
}
|
||||
|
||||
if (predicate())
|
||||
return true;
|
||||
|
Loading…
Reference in New Issue
Block a user