FlameGraph: Verify that window is exposed in test

Change-Id: I54b434d41f25227b48be21c60e82ff5294aae1c1
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
This commit is contained in:
Ulf Hermann
2018-01-03 10:47:18 +01:00
parent e07bf2f682
commit 2b99623605

View File

@@ -46,7 +46,7 @@ void FlameGraphViewTest::initTestCase()
QCOMPARE(manager.state(), QmlProfilerModelManager::Done);
view.resize(500, 500);
view.show();
QTest::qWaitForWindowExposed(&view);
QVERIFY(QTest::qWaitForWindowExposed(&view));
}
void FlameGraphViewTest::testSelection()
@@ -110,7 +110,7 @@ void FlameGraphViewTest::testContextMenu()
testMenu.addActions(QmlProfilerTool::profilerContextMenuActions());
testMenu.addSeparator();
testMenu.show();
QTest::qWaitForWindowExposed(testMenu.window());
QVERIFY(QTest::qWaitForWindowExposed(testMenu.window()));
targetWidth = testMenu.width() / 2;
int prevHeight = testMenu.height();
QAction dummy(QString("target"), this);