diff options
Diffstat (limited to 'tests/auto/quickcontrols2/controls/data/tst_container.qml')
-rw-r--r-- | tests/auto/quickcontrols2/controls/data/tst_container.qml | 84 |
1 files changed, 83 insertions, 1 deletions
diff --git a/tests/auto/quickcontrols2/controls/data/tst_container.qml b/tests/auto/quickcontrols2/controls/data/tst_container.qml index be2b9a12ba..5fa3137ade 100644 --- a/tests/auto/quickcontrols2/controls/data/tst_container.qml +++ b/tests/auto/quickcontrols2/controls/data/tst_container.qml @@ -169,7 +169,7 @@ TestCase { // don't crash (QTBUG-61310) function test_repeater(data) { - var control = createTemporaryObject(data.component) + var control = createTemporaryObject(data.component, testCase) verify(control) compare(control.itemAt(0).objectName, "0") @@ -213,4 +213,86 @@ TestCase { wait(1) verify(item3) } + + Component { + id: contentItemDeletionOrder1 + + Item { + objectName: "parentItem" + + Item { + id: item + objectName: "contentItem" + } + Container { + objectName: "control" + contentItem: item + } + } + } + + Component { + id: contentItemDeletionOrder2 + + Item { + objectName: "parentItem" + + Container { + objectName: "control" + contentItem: item + } + Item { + id: item + objectName: "contentItem" + } + } + } + + function test_contentItemDeletionOrder() { + var control1 = createTemporaryObject(contentItemDeletionOrder1, testCase) + verify(control1) + var control2 = createTemporaryObject(contentItemDeletionOrder2, testCase) + verify(control2) + } + + Component { + id: backgroundDeletionOrder1 + + Item { + objectName: "parentItem" + + Item { + id: item + objectName: "backgroundItem" + } + Container { + objectName: "control" + background: item + } + } + } + + Component { + id: backgroundDeletionOrder2 + + Item { + objectName: "parentItem" + + Container { + objectName: "control" + background: item + } + Item { + id: item + objectName: "backgroundItem" + } + } + } + + function test_backgroundDeletionOrder() { + var control1 = createTemporaryObject(backgroundDeletionOrder1, testCase) + verify(control1) + var control2 = createTemporaryObject(backgroundDeletionOrder2, testCase) + verify(control2) + } } |