Merge lp:~diegosarmentero/unity8/publisher-info into lp:unity8

Proposed by Diego Sarmentero
Status: Rejected
Rejected by: Michael Zanetti
Proposed branch: lp:~diegosarmentero/unity8/publisher-info
Merge into: lp:unity8
Diff against target: 130 lines (+36/-6)
3 files modified
Dash/Apps/AppInfo.qml (+18/-2)
Dash/Apps/AppPreview.qml (+6/-3)
tests/qmltests/Dash/Apps/tst_AppPreview.qml (+12/-1)
To merge this branch: bzr merge lp:~diegosarmentero/unity8/publisher-info
Reviewer Review Type Date Requested Status
Michael Zanetti (community) Disapprove
PS Jenkins bot (community) continuous-integration Needs Fixing
dobey (community) Approve
Review via email: mp+188352@code.launchpad.net

Commit message

- Add publisher information to App Preview.
- Disable Rates stars because they are not interactive yet, and we are not using the service.

Without Publisher information: http://ubuntuone.com/6uRD60aMxwvWMnah9rL79q
With Publisher information: http://ubuntuone.com/6KU0lJm0GK4eSnSXThQR5j

To post a comment you must log in.
364. By Diego Sarmentero

removing rating stars

365. By Diego Sarmentero

tests fixed

Revision history for this message
dobey (dobey) :
review: Approve
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :

FAILED: Continuous integration, rev:363
http://jenkins.qa.ubuntu.com/job/unity8-ci/1170/
Executed test runs:
    UNSTABLE: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-saucy/4188
    UNSTABLE: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-touch/1855
    SUCCESS: http://jenkins.qa.ubuntu.com/job/unity-phablet-qmluitests-saucy/1932
    SUCCESS: http://jenkins.qa.ubuntu.com/job/unity8-saucy-amd64-ci/193
    SUCCESS: http://jenkins.qa.ubuntu.com/job/unity8-saucy-armhf-ci/1170
        deb: http://jenkins.qa.ubuntu.com/job/unity8-saucy-armhf-ci/1170/artifact/work/output/*zip*/output.zip
    SUCCESS: http://jenkins.qa.ubuntu.com/job/unity8-saucy-i386-ci/1169
    UNSTABLE: http://jenkins.qa.ubuntu.com/job/autopilot-testrunner-otto-saucy/483
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-saucy-amd64/56
        deb: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-saucy-amd64/56/artifact/work/output/*zip*/output.zip
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-saucy-armhf/1857
        deb: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-saucy-armhf/1857/artifact/work/output/*zip*/output.zip
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-runner-maguro/1553
    UNSTABLE: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-runner-mako/1565

Click here to trigger a rebuild:
http://s-jenkins:8080/job/unity8-ci/1170/rebuild

review: Needs Fixing (continuous-integration)
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :

FAILED: Continuous integration, rev:365
http://jenkins.qa.ubuntu.com/job/unity8-ci/1178/
Executed test runs:
    UNSTABLE: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-saucy/4212
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-touch/1879
    SUCCESS: http://jenkins.qa.ubuntu.com/job/unity-phablet-qmluitests-saucy/1941
    SUCCESS: http://jenkins.qa.ubuntu.com/job/unity8-saucy-amd64-ci/201
    SUCCESS: http://jenkins.qa.ubuntu.com/job/unity8-saucy-armhf-ci/1178
        deb: http://jenkins.qa.ubuntu.com/job/unity8-saucy-armhf-ci/1178/artifact/work/output/*zip*/output.zip
    SUCCESS: http://jenkins.qa.ubuntu.com/job/unity8-saucy-i386-ci/1177
    UNSTABLE: http://jenkins.qa.ubuntu.com/job/autopilot-testrunner-otto-saucy/505
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-saucy-amd64/79
        deb: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-saucy-amd64/79/artifact/work/output/*zip*/output.zip
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-saucy-armhf/1881
        deb: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-saucy-armhf/1881/artifact/work/output/*zip*/output.zip
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-runner-maguro/1577
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-runner-mako/1590

Click here to trigger a rebuild:
http://s-jenkins:8080/job/unity8-ci/1178/rebuild

review: Needs Fixing (continuous-integration)
Revision history for this message
Michael Zanetti (mzanetti) wrote :

This will badly conflict with https://code.launchpad.net/~unity-team/unity8/fix-genericpreview/+merge/188355

I will take the changes from this branch and integrate them into the other.

Revision history for this message
Michael Zanetti (mzanetti) wrote :

Ok, integrated those changes into the new branch. Diego, please give it a look:

https://code.launchpad.net/~unity-team/unity8/fix-genericpreview/+merge/188355

It's revision 372.

review: Disapprove

Unmerged revisions

365. By Diego Sarmentero

tests fixed

364. By Diego Sarmentero

removing rating stars

363. By Diego Sarmentero

link bug

362. By Diego Sarmentero

adding publisher information to the app preview

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'Dash/Apps/AppInfo.qml'
2--- Dash/Apps/AppInfo.qml 2013-08-16 15:54:47 +0000
3+++ Dash/Apps/AppInfo.qml 2013-09-30 15:42:38 +0000
4@@ -22,6 +22,7 @@
5 id: root
6 property alias icon: image.source
7 property alias appName: appNameLabel.text
8+ property alias publisher: publisherNameLabel.text
9 property alias rating: ratingStars.rating
10 property int rated: 0
11 property int reviews: 0
12@@ -30,8 +31,8 @@
13
14 UbuntuShape {
15 id: imageShape
16- width: units.gu(6)
17- height: units.gu(6)
18+ width: colInfo.childrenRect.height < (root.width - rowStars.width - colInfo.spacing) ? colInfo.childrenRect.height : units.gu(10)
19+ height: colInfo.childrenRect.height < (root.width - rowStars.width - colInfo.spacing) ? colInfo.childrenRect.height : units.gu(10)
20 image: Image {
21 id: image
22 sourceSize { width: imageShape.width; height: imageShape.height }
23@@ -52,6 +53,21 @@
24 opacity: .9
25 }
26
27+ Label {
28+ id: publisherNameLabel
29+ visible: publisherNameLabel.text.length > 0 ? true : false
30+ fontSize: "medium"
31+ color: "white"
32+ style: Text.Raised
33+ styleColor: "black"
34+ opacity: .9
35+ anchors {
36+ left: parent.left
37+ right: parent.right
38+ }
39+ wrapMode: Text.WrapAtWordBoundaryOrAnywhere
40+ }
41+
42 Row {
43 visible: root.rating >= 0
44 spacing: units.gu(1)
45
46=== modified file 'Dash/Apps/AppPreview.qml'
47--- Dash/Apps/AppPreview.qml 2013-09-26 18:55:06 +0000
48+++ Dash/Apps/AppPreview.qml 2013-09-30 15:42:38 +0000
49@@ -140,6 +140,7 @@
50 anchors { left: parent.left; right: parent.right }
51
52 appName: root.previewData.title
53+ publisher: root.previewData.infoMap["publisher"] ? root.previewData.infoMap["publisher"].value : ""
54 icon: root.previewData.appIcon
55 rating: Math.round(root.previewData.rating * 10)
56 reviews: root.previewData.numRatings
57@@ -158,7 +159,11 @@
58 }
59
60 Column {
61- visible: root.previewData.rating >= 0
62+ id: columnReviewRating
63+ objectName: "columnReviewRating"
64+ // TODO: This should make this visible when the feature for reviews/comments is complete.
65+ // This should be enabled when the feature is complete: visible: root.previewData.rating >= 0
66+ visible: false
67 anchors { left: parent.left; right: parent.right }
68 spacing: parent.spacing
69
70@@ -193,8 +198,6 @@
71 AppReviews {
72 id: appReviews
73 objectName: "appReviews"
74- // TODO: This should make this visible when the feature for reviews/comments is complete.
75- visible: false
76 anchors { left: parent.left; right: parent.right }
77
78 model: root.previewData.infoMap["comments"] ? root.previewData.infoMap["comments"].value : undefined
79
80=== modified file 'tests/qmltests/Dash/Apps/tst_AppPreview.qml'
81--- tests/qmltests/Dash/Apps/tst_AppPreview.qml 2013-09-26 18:55:06 +0000
82+++ tests/qmltests/Dash/Apps/tst_AppPreview.qml 2013-09-30 15:42:38 +0000
83@@ -42,6 +42,7 @@
84 QtObject { id: rated; property int value: 120 }
85 QtObject { id: reviews; property int value: 8 }
86 QtObject { id: progress; property string value: "source" }
87+ QtObject { id: publisher; property string value: "Ubuntu Developer" }
88 QtObject { id: comments; property var value: [
89 ["Unity User", 4, "08/20/2013", root.commentary],
90 ["Unity User", 8, "01/15/2013", root.commentary],
91@@ -62,7 +63,8 @@
92 property var infoMap: {
93 "more-screenshots": screenshots,
94 "rated": rated,
95- "comments": comments
96+ "comments": comments,
97+ "publisher": publisher
98 }
99 property var actions: [
100 { "id": 123, "displayName": "action1" },
101@@ -84,6 +86,7 @@
102 "more-screenshots": screenshots,
103 "rated": rated,
104 "comments": comments,
105+ "publisher": publisher,
106 "progressbar_source": progressSource
107 }
108 property var actions: [
109@@ -137,6 +140,12 @@
110 }
111 }
112
113+ function test_check_app_info() {
114+ var appInfo = findChild(appPreview, "appInfo");
115+ compare(appInfo.appName, data.title, "App Title doesn't match.");
116+ compare(appInfo.publisher, publisher.value, "Publisher name doesn't match.");
117+ }
118+
119 function test_rated() {
120 var rated = findChild(appPreview, "ratedLabel");
121 compare(rated.text, "(120)", "Rates not equal");
122@@ -154,6 +163,8 @@
123 }
124
125 function test_review_focus() {
126+ var columnReviewRating = findChild(appPreview, "columnReviewRating");
127+ columnReviewRating.visible = true;
128 var appReviews = findChild(appPreview, "appReviews");
129 appReviews.visible = true;
130 var sendButton = findChild(appReviews, "sendButton");

Subscribers

People subscribed via source and target branches