Use a precise timer in tst_QTimer::remainingTime

At 200 ms, the error on first firing could be 10 ms.

Task-number: QTBUG-58519
Change-Id: Ifaee7464122d402991b6fffd14a02a4ce782f11f
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
This commit is contained in:
Thiago Macieira 2017-02-04 10:52:12 -08:00
parent e08f764fa7
commit 239418a947

View File

@ -158,6 +158,7 @@ void tst_QTimer::remainingTime()
QTimer timer;
connect(&timer, SIGNAL(timeout()), &helper, SLOT(timeout()));
timer.setTimerType(Qt::PreciseTimer);
timer.start(200);
QCOMPARE(helper.count, 0);