aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto/controls/data/tst_tabbar.qml
diff options
context:
space:
mode:
Diffstat (limited to 'tests/auto/controls/data/tst_tabbar.qml')
-rw-r--r--tests/auto/controls/data/tst_tabbar.qml20
1 files changed, 5 insertions, 15 deletions
diff --git a/tests/auto/controls/data/tst_tabbar.qml b/tests/auto/controls/data/tst_tabbar.qml
index 92e80952..da0181a1 100644
--- a/tests/auto/controls/data/tst_tabbar.qml
+++ b/tests/auto/controls/data/tst_tabbar.qml
@@ -85,19 +85,9 @@ TestCase {
}
}
- SignalSpy {
- id: contentChildrenSpy
- signalName: "contentChildrenChanged"
- }
-
- function init() {
- verify(!contentChildrenSpy.target)
- compare(contentChildrenSpy.count, 0)
- }
-
- function cleanup() {
- contentChildrenSpy.target = null
- contentChildrenSpy.clear()
+ Component {
+ id: signalSpy
+ SignalSpy { }
}
function test_defaults() {
@@ -186,7 +176,7 @@ TestCase {
control.currentIndexChanged.connect(verifyCurrentIndexCountDiff)
control.countChanged.connect(verifyCurrentIndexCountDiff)
- contentChildrenSpy.target = control
+ var contentChildrenSpy = signalSpy.createObject(testCase, {target: control, signalName: "contentChildrenChanged"})
verify(contentChildrenSpy.valid)
compare(control.count, 0)
@@ -303,7 +293,7 @@ TestCase {
return true
}
- contentChildrenSpy.target = control
+ var contentChildrenSpy = signalSpy.createObject(testCase, {target: control, signalName: "contentChildrenChanged"})
verify(contentChildrenSpy.valid)
verify(compareObjectNames(control.contentData, ["object", "button1", "timer", "button2", ""]))