[autotest] Make SlidingPopupsTest a little bit more robust

The first test case was sometimes failing due to the time value in the
first render pass being too high. So that the effect ended directly for
the window.

This change adds a small waiting time for the compositor to render prior
to the creation of the window. Ideally we would connect to frameRendered
signal, but the OpenGL compositor doesn't emit it yet.
This commit is contained in:
Martin Gräßlin 2016-10-31 08:55:54 +01:00
parent 3aeb7367bb
commit e4930c0c41

View file

@ -170,6 +170,10 @@ void SlidingPopupsTest::testWithOtherEffect()
QVERIFY(!slidingPoupus->isActive());
QVERIFY(!otherEffect->isActive());
// give the compositor some time to render
QTest::qWait(50);
QSignalSpy windowAddedSpy(effects, &EffectsHandler::windowAdded);
QVERIFY(windowAddedSpy.isValid());