diff options
author | J-P Nurmi <jpnurmi@qt.io> | 2016-09-03 15:15:53 +0200 |
---|---|---|
committer | J-P Nurmi <jpnurmi@qt.io> | 2016-09-05 11:03:54 +0000 |
commit | a0d77ff082b6a5aa02a36f5a82649c45c0dcd265 (patch) | |
tree | 7c711e3311612d1d8633d7af503a29f81cb49c45 /tests/auto/menu/tst_menu.cpp | |
parent | 28daf8cc73c6ba51bcdda3079d73c2db7919fc2a (diff) |
auto tests: allow using QQuickWindow with QQuickApplicationHelper
This allows us to run the relevant popup tests for both QQuickWindow
and QQuickApplicationWindow.
Change-Id: I14b6435afeeb8a6cf640d8c52ad1d9e1fae070b0
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
Diffstat (limited to 'tests/auto/menu/tst_menu.cpp')
-rw-r--r-- | tests/auto/menu/tst_menu.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/tests/auto/menu/tst_menu.cpp b/tests/auto/menu/tst_menu.cpp index dc9c296a..7617cfcc 100644 --- a/tests/auto/menu/tst_menu.cpp +++ b/tests/auto/menu/tst_menu.cpp @@ -71,7 +71,7 @@ void tst_menu::defaults() { QQuickApplicationHelper helper(this, QLatin1String("applicationwindow.qml")); - QQuickMenu *emptyMenu = helper.window->property("emptyMenu").value<QQuickMenu*>(); + QQuickMenu *emptyMenu = helper.appWindow->property("emptyMenu").value<QQuickMenu*>(); QCOMPARE(emptyMenu->isVisible(), false); QCOMPARE(emptyMenu->contentItem()->property("currentIndex"), QVariant(-1)); } @@ -80,7 +80,7 @@ void tst_menu::mouse() { QQuickApplicationHelper helper(this, QLatin1String("applicationwindow.qml")); - QQuickApplicationWindow *window = helper.window; + QQuickApplicationWindow *window = helper.appWindow; window->show(); QVERIFY(QTest::qWaitForWindowActive(window)); @@ -152,7 +152,7 @@ void tst_menu::contextMenuKeyboard() QQuickApplicationHelper helper(this, QLatin1String("applicationwindow.qml")); - QQuickApplicationWindow *window = helper.window; + QQuickApplicationWindow *window = helper.appWindow; window->show(); window->requestActivate(); QVERIFY(QTest::qWaitForWindowActive(window)); @@ -230,7 +230,7 @@ void tst_menu::menuButton() QQuickApplicationHelper helper(this, QLatin1String("applicationwindow.qml")); - QQuickApplicationWindow *window = helper.window; + QQuickApplicationWindow *window = helper.appWindow; window->show(); window->requestActivate(); QVERIFY(QTest::qWaitForWindowActive(window)); @@ -254,7 +254,7 @@ void tst_menu::menuButton() void tst_menu::addItem() { QQuickApplicationHelper helper(this, QLatin1String("addItem.qml")); - QQuickApplicationWindow *window = helper.window; + QQuickApplicationWindow *window = helper.appWindow; window->show(); QVERIFY(QTest::qWaitForWindowActive(window)); |