on xenial help sign in
Account for reordering of scopes in the mock scopes
7051a34Albert Astals
tests/qmltests/Dash/tst_DashContent.qml+6−6
@@ -131,7 +131,7 @@ Item {
131 function test_show_header_on_list_movement() {
131 function test_show_header_on_list_movement() {
132 var dashContentList = findChild(dashContent, "dashContentList");
132 var dashContentList = findChild(dashContent, "dashContentList");
133 verify(dashContentList !== null);
133 verify(dashContentList !== null);
134− var scope = findChild(dashContent, "MockScope1 loader");
134+ var scope = findChild(dashContent, "clickscope loader");
135 waitForRendering(scope);
135 waitForRendering(scope);
136
136
137 var categoryListView = findChild(scope, "categoryListView");
137 var categoryListView = findChild(scope, "categoryListView");
@@ -149,19 +149,19 @@ Item {
149 function test_set_current_scope_reset() {
149 function test_set_current_scope_reset() {
150 var dashContentList = findChild(dashContent, "dashContentList");
150 var dashContentList = findChild(dashContent, "dashContentList");
151 verify(dashContentList, "Couldn't find dashContentList");
151 verify(dashContentList, "Couldn't find dashContentList");
152− var scope = findChild(dashContent, "MockScope1 loader");
152+ var scope = findChild(dashContent, "clickscope loader");
153
153
154 tryCompare(scope, "status", Loader.Ready);
154 tryCompare(scope, "status", Loader.Ready);
155
155
156 var categoryListView = findChild(dashContentList, "categoryListView");
156 var categoryListView = findChild(dashContentList, "categoryListView");
157 categoryListView.contentY = units.gu(10);
157 categoryListView.contentY = units.gu(10);
158
158
159− compare(dashContentList.currentItem.item.objectName, "MockScope1")
159+ compare(dashContentList.currentItem.item.objectName, "clickscope")
160 compare(categoryListView.contentY, units.gu(10));
160 compare(categoryListView.contentY, units.gu(10));
161
161
162 dashContent.setCurrentScopeAtIndex(0, false, true);
162 dashContent.setCurrentScopeAtIndex(0, false, true);
163
163
164− compare(dashContentList.currentItem.item.objectName, "MockScope1")
164+ compare(dashContentList.currentItem.item.objectName, "clickscope")
165 compare(categoryListView.contentY, 0);
165 compare(categoryListView.contentY, 0);
166 }
166 }
167
167
@@ -199,8 +199,8 @@ Item {
199
199
200 function test_scope_mapping_data() {
200 function test_scope_mapping_data() {
201 return [
201 return [
202− {tag: "index0", index: 0, objectName: "MockScope1"},
202+ {tag: "index0", index: 0, objectName: "clickscope"},
203− {tag: "index1", index: 1, objectName: "clickscope"},
203+ {tag: "index1", index: 1, objectName: "MockScope1"},
204 {tag: "index2", index: 2, objectName: "MockScope5"},
204 {tag: "index2", index: 2, objectName: "MockScope5"},
205 {tag: "index3", index: 3, objectName: "SingleCategoryScope"}
205 {tag: "index3", index: 3, objectName: "SingleCategoryScope"}
206 ]
206 ]