on xenial help sign in
fixed tests
30bfc5aNick Dedekind
qml/Panel/Indicators/IndicatorBase.qml+3−4
@@ -18,8 +18,7 @@
18 */
18 */
19
19
20import QtQuick 2.0
20import QtQuick 2.0
21−import QMenuModel 0.1 as QMenuModel
22−import Unity.Indicators 0.1 as Indicators
21+import Unity.Indicators 0.1
23
22
24Item {
23Item {
25 id: indicatorItem
24 id: indicatorItem
@@ -36,14 +35,14 @@ Item {
36
35
37 property alias menuModel: cachedModel.model
36 property alias menuModel: cachedModel.model
38
37
39− Indicators.CachedUnityMenuModel {
38+ CachedUnityMenuModel {
40 id: cachedModel
39 id: cachedModel
41 busName: indicatorItem.busName
40 busName: indicatorItem.busName
42 actionsObjectPath: indicatorItem.actionsObjectPath
41 actionsObjectPath: indicatorItem.actionsObjectPath
43 menuObjectPath: indicatorItem.deviceMenuObjectPath
42 menuObjectPath: indicatorItem.deviceMenuObjectPath
44 }
43 }
45
44
46− property var rootActionState: Indicators.RootActionState {
45+ property RootActionState rootActionState: RootActionState {
47 menu: menuModel
46 menu: menuModel
48 onUpdated: indicatorItem.rootActionStateChanged()
47 onUpdated: indicatorItem.rootActionStateChanged()
49 }
48 }
tests/mocks/Unity/Indicators/IndicatorBase.qmldeleted−38
@@ -1,38 +0,0 @@
1−/*
2− * Copyright 2013 Canonical Ltd.
3− *
4− * This program is free software; you can redistribute it and/or modify
5− * it under the terms of the GNU Lesser General Public License as published by
6− * the Free Software Foundation; version 3.
7− *
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 Lesser General Public License for more details.
12− *
13− * You should have received a copy of the GNU Lesser General Public License
14− * along with this program. If not, see <http://www.gnu.org/licenses/>.
15− *
16− * Authors:
17− * Nick Dedekind <nick.dedekind@canonical.com>
18− */
19−
20−import QtQuick 2.0
21−import QMenuModel 0.1
22−
23−Item {
24− id: indicatorBase
25−
26− //const
27− property string busName
28− property string actionsObjectPath
29− property string menuObjectPath
30− property string rootMenuType: "com.canonical.indicator.root"
31− property string deviceMenuObjectPath: menuObjectPath
32−
33− property var menuModel: UnityMenuModel {}
34−
35− property RootActionState rootActionState: RootActionState {
36− onUpdated: indicatorBase.rootActionStateChanged()
37− }
38−}
tests/mocks/Unity/Indicators/qmldir−1
@@ -3,7 +3,6 @@ plugin IndicatorsFakeQml
3typeinfo Indicators.qmltypes
3typeinfo Indicators.qmltypes
4
4
5CachedUnityMenuModel 0.1 CachedUnityMenuModel.qml
5CachedUnityMenuModel 0.1 CachedUnityMenuModel.qml
6−IndicatorBase 0.1 IndicatorBase.qml
7IndicatorsModel 0.1 IndicatorsModel.qml
6IndicatorsModel 0.1 IndicatorsModel.qml
8FakeMenuPage 0.1 FakeMenuPage.qml
7FakeMenuPage 0.1 FakeMenuPage.qml
9RootActionState 0.1 RootActionState.qml
8RootActionState 0.1 RootActionState.qml
tests/qmltests/Panel/Indicators/tst_DefaultIndicatorPage.qml+1
@@ -31,6 +31,7 @@ Item {
31 anchors.fill: parent
31 anchors.fill: parent
32 contentActive: true
32 contentActive: true
33
33
34+ menuModel: UnityMenuModel {}
34 busName: "test"
35 busName: "test"
35 actionsObjectPath: "test"
36 actionsObjectPath: "test"
36 menuObjectPath: "test"
37 menuObjectPath: "test"
tests/qmltests/Panel/Indicators/tst_DefaultIndicatorWidget.qml+1
@@ -33,6 +33,7 @@ Item {
33 top: parent.top
33 top: parent.top
34 }
34 }
35
35
36+ menuModel: UnityMenuModel {}
36 busName: "test"
37 busName: "test"
37 actionsObjectPath: "test"
38 actionsObjectPath: "test"
38 deviceMenuObjectPath: "test"
39 deviceMenuObjectPath: "test"