Add a condition for art.height not being 0
means stuff has already been layouted a bit
without it it can happen that we get 0 for everything at startup and tests still pass
commitb332752bef629cd8674397dc6ca084e37d4a591a
authorAlbert Astals <albert.astals@canonical.com>
dateMon 28 Jul 2014, 10:16 (12 years ago)
parentbb83003
tests/qmltests/Dash/tst_Card.qml+1−1
@@ -359,7 +359,7 @@ Rectangle {
359359
360360 waitForRendering(card);
361361
362− tryCompareFunction(function() { return testCase.summary.y === data.top() }, true);
362+ tryCompareFunction(function() { return art.height > 0 && testCase.summary.y === data.top() }, true);
363363 }
364364
365365 function test_art_visibility() {