tst_QGraphicsEffectSource: Reset effect repaint count after flushing events

Follow-up to 8222e06d12a4e2a84ce1161abd0ceb58622c740b, which only reset
the item repaint count.

Flushing the queued paint events will bump numRepaints, and the whole
point of calling reset() is to prepare a consistent state before the
next test, so we need to call it after flushing the events.

Pick-to: 6.2 6.4
Change-Id: Id1fe840c14c0940d7020cf8f8cc6a3aeceaa5fb5
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
This commit is contained in:
Tor Arne Vestbø 2022-11-04 14:39:18 +01:00
parent 3d03001d2d
commit fe67c69643

View File

@ -154,10 +154,10 @@ void tst_QGraphicsEffectSource::init()
QVERIFY(effect);
QVERIFY(item);
QVERIFY(effect->source());
effect->reset();
effect->storeDeviceDependentStuff = false;
effect->doNothingInDraw = false;
QCoreApplication::processEvents(); // Process all queued paint events
effect->reset();
item->reset();
}