on xenial help sign in
Merge card-tool.
9fb61f5Michał Sawicz
qml/Dash/CardTool.qml+1−2
@@ -105,10 +105,9 @@ Item {
105 */
105 */
106 readonly property alias headerHeight: card.headerHeight
106 readonly property alias headerHeight: card.headerHeight
107
107
108− readonly property QtObject priv: card
109−
110 Card {
108 Card {
111 id: card
109 id: card
110+ objectName: "card"
112 template: cardTool.template
111 template: cardTool.template
113 components: cardTool.components
112 components: cardTool.components
114
113
tests/qmltests/Dash/tst_CardTool.qml+7−1
@@ -209,7 +209,7 @@ Rectangle {
209 id: dataArea
209 id: dataArea
210 anchors { left: parent.left; right: parent.right }
210 anchors { left: parent.left; right: parent.right }
211 height: units.gu(25)
211 height: units.gu(25)
212− text: JSON.stringify(cardTool.priv.cardData, undefined, 2)
212+ text: JSON.stringify(testCase.internalCard.cardData, undefined, 2)
213 }
213 }
214
214
215 Label {
215 Label {
@@ -239,8 +239,14 @@ Rectangle {
239 id: testCase
239 id: testCase
240 name: "Card"
240 name: "Card"
241
241
242+ property Card internalCard: findChild(cardTool, "card")
243+
242 when: windowShown
244 when: windowShown
243
245
246+ function init() {
247+ verify(typeof testCase.internalCard === "object", "Couldn't find internal card object.");
248+ }
249+
244 function cleanup() {
250 function cleanup() {
245 selector.selectedIndex = -1;
251 selector.selectedIndex = -1;
246 layoutSelector.selectedIndex = -1;
252 layoutSelector.selectedIndex = -1;