@@ -571,10 +571,12 @@ Item {
571 waitForRendering(notifications);
571 waitForRendering(notifications);
573 var notification = findChild(notifications, "notification" + (mockModel.count - 1))
573 var notification = findChild(notifications, "notification" + (mockModel.count - 1))
574− verify(notification !== undefined, "notification wasn't found");
576 waitForRendering(notification);
574 waitForRendering(notification);
575+ verify(notification, "notification wasn't found");
577+ var topRow = findChild(notification, "topRow");
577− tryCompare(notification, "height", notification.state === "contracted" ? units.gu(10) : notification.implicitHeight);
578+ tryCompare(notification, "height", notification.state === "contracted" ? topRow.childrenRect.height + notification.margins * 2
579+ : notification.implicitHeight);
579 var icon = findChild(notification, "icon")
581 var icon = findChild(notification, "icon")
580 var centeredIcon = findChild(notification, "centeredIcon")
582 var centeredIcon = findChild(notification, "centeredIcon")
@@ -585,7 +587,6 @@ Item {
585 var buttonRow = findChild(notification, "buttonRow")
587 var buttonRow = findChild(notification, "buttonRow")
586 var valueIndicator = findChild(notification, "valueIndicator")
588 var valueIndicator = findChild(notification, "valueIndicator")
587 var valueLabel = findChild(notification, "valueLabel")
589 var valueLabel = findChild(notification, "valueLabel")
588− var innerBar = findChild(notification, "innerBar")
590 compare(icon.visible, data.iconVisible, "avatar-icon visibility is incorrect")
591 compare(icon.visible, data.iconVisible, "avatar-icon visibility is incorrect")
591 if (icon.visible) {
592 if (icon.visible) {
@@ -596,9 +597,6 @@ Item {
596 compare(centeredIcon.shaped, data.shaped, "shaped-status is incorrect")
597 compare(centeredIcon.shaped, data.shaped, "shaped-status is incorrect")
598 compare(valueIndicator.visible, data.valueVisible, "value-indicator visibility is incorrect")
599 compare(valueIndicator.visible, data.valueVisible, "value-indicator visibility is incorrect")
599− if (valueIndicator.visible) {
600− verify(innerBar.color === data.valueTinted ? UbuntuColors.orange : "white", "value-bar has the wrong color-tint")
602 compare(valueLabel.visible, data.valueLabelVisible, "value-label visibility is incorrect")
600 compare(valueLabel.visible, data.valueLabelVisible, "value-label visibility is incorrect")
604 // test input does not fall through
602 // test input does not fall through
@@ -618,7 +616,9 @@ Item {
618 // for their height animations to finish before continuing
616 // for their height animations to finish before continuing
619 for (var i = 0; i < mockModel.count; ++i) {
617 for (var i = 0; i < mockModel.count; ++i) {
620 var n = findChild(notifications, "notification" + i)
618 var n = findChild(notifications, "notification" + i)
619+ waitForRendering(n);
620+ var topRow = findChild(n, "topRow");
621− tryCompare(n, "height", n.state === "contracted" ? units.gu(10) : n.implicitHeight);
621+ tryCompare(n, "height", n.state === "contracted" ? topRow.childrenRect.height + n.margins * 2 : n.implicitHeight);
624 if (data.hasSound) {
624 if (data.hasSound) {
@@ -651,7 +651,7 @@ Item {
651 tryCompareFunction(function() { return comboButton.expanded === false; }, true);
651 tryCompareFunction(function() { return comboButton.expanded === false; }, true);
653 // click to expand
653 // click to expand
654− tryCompareFunction(function() { mouseClick(comboButton, comboButton.width / 2, comboButton.height / 2); return comboButton.expanded === true; }, true);
654+ tryCompareFunction(function() { mouseClick(comboButton, comboButton.width / 2, comboButton.height / 2); return comboButton.expanded; }, true);
656 // try clicking on choices in expanded comboList
656 // try clicking on choices in expanded comboList
657 var choiceButton1 = findChild(notification, "notify_button3")
657 var choiceButton1 = findChild(notification, "notify_button3")
@@ -665,7 +665,7 @@ Item {
665 actionSpy.clear()
665 actionSpy.clear()
667 // click to collapse
667 // click to collapse
668− tryCompareFunction(function() { mouseClick(comboButton, comboButton.width / 2, comboButton.height / 2); return comboButton.expanded == false; }, true);
668+ tryCompareFunction(function() { mouseClick(comboButton, comboButton.width / 2, comboButton.height / 2); return !comboButton.expanded; }, true);
670 mouseClick(buttonCancel)
670 mouseClick(buttonCancel)
671 compare(actionSpy.signalArguments[0][0], data.n.actions.data(1, ActionModel.RoleActionId), "got wrong id for negative action")
671 compare(actionSpy.signalArguments[0][0], data.n.actions.data(1, ActionModel.RoleActionId), "got wrong id for negative action")