on xenial help sign in
added desktop test case
8f37452Nick Dedekind
tests/qmltests/tst_Shell.qml+23−4
@@ -103,6 +103,23 @@ Rectangle {
103 GSettingsController.setUsageMode("com.canonical.Unity8", "Staged")
103 GSettingsController.setUsageMode("com.canonical.Unity8", "Staged")
104 }
104 }
105 }
105 }
106+ },
107+ State {
108+ name: "desktop"
109+ PropertyChanges {
110+ target: shellLoader
111+ width: units.gu(100)
112+ height: units.gu(71)
113+ }
114+ PropertyChanges {
115+ target: mouseEmulation
116+ checked: false
117+ }
118+ StateChangeScript {
119+ script: {
120+ GSettingsController.setUsageMode("com.canonical.Unity8", "Windowed")
121+ }
122+ }
106 }
123 }
107 ]
124 ]
108
125
@@ -160,7 +177,7 @@ Rectangle {
160 anchors { left: parent.left; right: parent.right }
177 anchors { left: parent.left; right: parent.right }
161 activeFocusOnPress: false
178 activeFocusOnPress: false
162 text: "Size"
179 text: "Size"
163− model: ["phone", "tablet"]
180+ model: ["phone", "tablet", "desktop"]
164 onSelectedIndexChanged: {
181 onSelectedIndexChanged: {
165 shellLoader.active = false;
182 shellLoader.active = false;
166 shellLoader.state = model[selectedIndex];
183 shellLoader.state = model[selectedIndex];
@@ -713,8 +730,9 @@ Rectangle {
713
730
714 function test_launchedAppHasActiveFocus_data() {
731 function test_launchedAppHasActiveFocus_data() {
715 return [
732 return [
716− {tag:"phone", formFactor:"phone"},
733+ {tag: "phone", formFactor: "phone"},
717− {tag:"tablet", formFactor:"tablet"},
734+ {tag: "tablet", formFactor: "tablet"},
735+ {tag: "desktop", formFactor: "desktop"}
718 ];
736 ];
719 }
737 }
720
738
@@ -1210,7 +1228,8 @@ Rectangle {
1210 function test_stageLoader_data() {
1228 function test_stageLoader_data() {
1211 return [
1229 return [
1212 {tag: "phone", source: "Stages/PhoneStage.qml"},
1230 {tag: "phone", source: "Stages/PhoneStage.qml"},
1213− {tag: "tablet", source: "Stages/TabletStage.qml"}
1231+ {tag: "tablet", source: "Stages/TabletStage.qml"},
1232+ {tag: "desktop", source: "Stages/DesktopStage.qml"}
1214 ]
1233 ]
1215 }
1234 }
1216
1235