@@ -50,9 +50,6 @@ Item {
5050 });
5151
5252 verify(cachedObject.model !== cachedObject2.model);
53−
54− cachedObject.destroy();
55− cachedObject2.destroy();
5653 }
5754
5855 function test_createSame() {
@@ -71,53 +68,6 @@ Item {
7168 });
7269
7370 verify(cachedObject.model === cachedObject2.model);
74−
75− cachedObject.destroy();
76− cachedObject2.destroy();
77− }
78−
79− function test_destroyAllDeletesModel() {
80− var cachedObject = model.createObject(root,
81− {
82− "busName": "com.canonical.test1",
83− "menuObjectPath": "com/canonical/test1",
84− "actionsObjectPath": "com/canonical/test1/actions"
85− });
86−
87− var cachedObject2 = model.createObject(root,
88− {
89− "busName": "com.canonical.test1",
90− "menuObjectPath": "com/canonical/test1",
91− "actionsObjectPath": "com/canonical/test1/actions"
92− });
93−
94− var menuModel = cachedObject.model;
95− cachedObject.destroy();
96− cachedObject2.destroy();
97− tryCompareFunction(function() { return Indicators.UnityMenuModelCache.contains(menuModel) }, false);
98− }
99−
100− function test_destroyPartialKeepsModel() {
101− var cachedObject = model.createObject(root,
102− {
103− "busName": "com.canonical.test1",
104− "menuObjectPath": "com/canonical/test1",
105− "actionsObjectPath": "com/canonical/test1/actions"
106− });
107−
108− var cachedObject2 = model.createObject(root,
109− {
110− "busName": "com.canonical.test1",
111− "menuObjectPath": "com/canonical/test1",
112− "actionsObjectPath": "com/canonical/test1/actions"
113− });
114−
115− var menuModel = cachedObject.model;
116− cachedObject.destroy();
117− wait(1);
118− compare(Indicators.UnityMenuModelCache.contains(menuModel), true);
119−
120− cachedObject2.destroy();
12171 }
12272
12373 // Tests that changing cached model data does not change the model path of others
@@ -141,9 +91,6 @@ Item {
14191 compare(cachedObject2.model.menuObjectPath, "com/canonical/test1");
14292
14393 verify(cachedObject.model !== cachedObject2.model);
144−
145− cachedObject.destroy();
146− cachedObject2.destroy();
14794 }
14895 }
14996}