on xenial help sign in
update tests
commit31ab38861b867f2a0e80a3f7200b5e17ff5d9ad1 authorMichael Zanetti <michael.zanetti@canonical.com> dateTue 1 Oct 2013, 20:07 (13 years ago) parent553929e
2 files changed+5−4
Dash/Generic/GenericPreview.qml+2−1 tests/qmltests/Dash/Apps/tst_AppPreview.qml+3−3
Dash/Generic/GenericPreview.qml+2−1
@@ -62,12 +62,13 @@ DashPreview {
6262
6363 Column {
6464 id: buttonList
65− objectName: "buttonList"
6665 spacing: units.gu(1)
6766 Repeater {
67+ objectName: "buttonList"
6868 model: previewData.actions
6969
7070 delegate: Button {
71+ objectName: "button" + index
7172 width: parent.width
7273 height: buttonList.buttonHeight
7374 color: Theme.palette.selected.foreground
tests/qmltests/Dash/Apps/tst_AppPreview.qml+3−3
@@ -127,12 +127,12 @@ Item {
127127 }
128128
129129 function test_actions() {
130− var buttons = findChild(appPreview, "gridButtons");
130+ var buttons = findChild(appPreview, "buttonList");
131131 compare(buttons.count, 3, "Not the proper amount of actions detected.");
132132
133133 for(var i = 0; i < buttons.count; i++) {
134− buttons.currentIndex = i;
135− buttons.currentItem.clicked();
134+ var button = findChild(appPreview, "button" + i);
135+ mouseClick(button, 1, 1);
136136 }
137137
138138 var actions = data.actions;