diff options
author | Friedemann Kleint <Friedemann.Kleint@qt.io> | 2016-04-28 14:11:28 +0200 |
---|---|---|
committer | Friedemann Kleint <Friedemann.Kleint@qt.io> | 2016-04-29 08:58:15 +0000 |
commit | 91f536dd71cd154675264c27273020f4de310ec2 (patch) | |
tree | a02f4385aaba33cb2192c57f1ef05a699c77afee /tests | |
parent | 3da965ccd9f3d89a0bea0d774d5f7384ad73afd7 (diff) |
tst_QMdiArea::subWindowActivated2(): Add activateWindow().
The widget is hidden, reshown and tested for active window, which
is flaky. Add a call to activateWindow() which increases
the chances of it becoming the active window should another window
appear.
Change-Id: Ibbecdbc43e2ac9638aec497c47fffaaffa1855af
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
Diffstat (limited to 'tests')
-rw-r--r-- | tests/auto/widgets/widgets/qmdiarea/tst_qmdiarea.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/tests/auto/widgets/widgets/qmdiarea/tst_qmdiarea.cpp b/tests/auto/widgets/widgets/qmdiarea/tst_qmdiarea.cpp index aa86e02465..57be110c15 100644 --- a/tests/auto/widgets/widgets/qmdiarea/tst_qmdiarea.cpp +++ b/tests/auto/widgets/widgets/qmdiarea/tst_qmdiarea.cpp @@ -497,6 +497,7 @@ void tst_QMdiArea::subWindowActivated2() spy.clear(); mdiArea.show(); + mdiArea.activateWindow(); QVERIFY(QTest::qWaitForWindowActive(&mdiArea)); QTRY_COMPARE(spy.count(), 1); QVERIFY(mdiArea.currentSubWindow()); |