@@ -0,0 +1,81 @@
2+ * Copyright 2014 Canonical Ltd.
4+ * This program is free software; you can redistribute it and/or modify
5+ * it under the terms of the GNU General Public License as published by
6+ * the Free Software Foundation; version 3.
8+ * This program is distributed in the hope that it will be useful,
9+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
10+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11+ * GNU General Public License for more details.
13+ * You should have received a copy of the GNU General Public License
14+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
19+import "../../../../qml/Dash/Previews"
20+import Unity.Test 0.1 as UT
21+import Ubuntu.Components 0.1
29+ property var actionDataOneAction: {
30+ "actions": [{"label": "Some Label", "icon": "../graphics/play_button.png", "id": "someid"}]
33+ property var actionDataTwoActions: {
34+ "actions": [{"label": "Some Label A", "icon": "../graphics/icon_clear.png", "id": "someid1"},
35+ {"label": "Some Label B", "icon": "../graphics/play_button.png", "id": "someid2"}
39+ property var actionDataFiveActions: {
40+ "actions": [{"label": "Some Label C", "icon": "../graphics/play_button.png", "id": "someid3"},
41+ {"label": "Some Label D", "icon": "../graphics/icon_clear.png", "id": "someid4"},
42+ {"label": "Some Label E", "icon": "../graphics/play_button.png", "id": "someid5"},
43+ {"label": "Some Label F", "icon": "../graphics/icon_clear.png", "id": "someid6"},
44+ {"label": "Some Label G", "icon": "../graphics/play_button.png", "id": "someid7"}
53+ widgetData: actionDataOneAction
54+ onTriggered: console.log("triggered", widgetId, actionId, data);
58+ widgetId: "buttonAndCombo"
59+ widgetData: actionDataFiveActions
60+ onTriggered: console.log("triggered", widgetId, actionId, data);
65+ widgetData: actionDataTwoActions
66+ onTriggered: console.log("triggered", widgetId, actionId, data);
71+ name: "PreviewActionTest"
74+ function test_changeEmptyModel() {
76+// imageGallery.widgetData = sourcesModel0;
77+// var placeholderScreenshot = findChild(imageGallery, "placeholderScreenshot");
78+// compare(placeholderScreenshot.visible, true);