diff options
author | Qt Forward Merge Bot <qt_forward_merge_bot@qt-project.org> | 2020-05-05 15:52:53 +0200 |
---|---|---|
committer | Qt Forward Merge Bot <qt_forward_merge_bot@qt-project.org> | 2020-05-05 15:52:54 +0200 |
commit | 9f6a3bf96fabeca58599029f9d9d59b7ed852569 (patch) | |
tree | d8a47b67c3b5817d1f5f77c312adbe655b1ca576 /tests | |
parent | e807f9d1d80559b8ff91f1c3cfdd755b3da56a6d (diff) | |
parent | a2eef6b511988b2435c4e39b6b5551e857ce7775 (diff) |
Merge remote-tracking branch 'origin/5.15' into dev
Change-Id: I0e495f3d59f2a507aeb73c013e1d8ec0668313c4
Diffstat (limited to 'tests')
-rw-r--r-- | tests/auto/quick/qquickaccessible/tst_qquickaccessible.cpp | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/tests/auto/quick/qquickaccessible/tst_qquickaccessible.cpp b/tests/auto/quick/qquickaccessible/tst_qquickaccessible.cpp index 061d5f8a1a..0e6c3b3ad9 100644 --- a/tests/auto/quick/qquickaccessible/tst_qquickaccessible.cpp +++ b/tests/auto/quick/qquickaccessible/tst_qquickaccessible.cpp @@ -169,9 +169,22 @@ void tst_QQuickAccessible::quickAttachedProperties() delete object; } - // Attached property + // Attaching to non-item { QObject parent; + QTest::ignoreMessage(QtWarningMsg, "<Unknown File>: QML QtObject: Accessible must be attached to an Item"); + QQuickAccessibleAttached *attachedObj = new QQuickAccessibleAttached(&parent); + + QCOMPARE(attachedObj->ignored(), false); + attachedObj->setIgnored(true); + QCOMPARE(attachedObj->ignored(), false); + attachedObj->setIgnored(false); + QCOMPARE(attachedObj->ignored(), false); + } + + // Attached property + { + QQuickItem parent; QQuickAccessibleAttached *attachedObj = new QQuickAccessibleAttached(&parent); attachedObj->name(); |