Merge lp:~paulliu/unity8/fix-zoomableimage-test1 into lp:unity8
- fix-zoomableimage-test1
- Merge into trunk
Status: | Merged | ||||
---|---|---|---|---|---|
Approved by: | Albert Astals Cid | ||||
Approved revision: | 886 | ||||
Merged at revision: | 918 | ||||
Proposed branch: | lp:~paulliu/unity8/fix-zoomableimage-test1 | ||||
Merge into: | lp:unity8 | ||||
Diff against target: |
134 lines (+31/-27) 2 files modified
tests/qmltests/Components/tst_ZoomableImage.qml (+21/-19) tests/qmltests/Dash/Previews/tst_PreviewZoomableImage.qml (+10/-8) |
||||
To merge this branch: | bzr merge lp:~paulliu/unity8/fix-zoomableimage-test1 | ||||
Related bugs: |
|
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Albert Astals Cid (community) | Approve | ||
PS Jenkins bot (community) | continuous-integration | Needs Fixing | |
Michał Sawicz | Needs Fixing | ||
Review via email: mp+218649@code.launchpad.net |
Commit message
Fix ZoomableImage test failure.
Description of the change
* Are there any related MPs required for this MP to build/function as expected?
No.
* Did you perform an exploratory manual test run of your code change and any related functionality?
Yes
* If you changed the packaging (debian), did you subscribe the ubuntu-unity team to this MP?
N/A
* If you changed the UI, has there been a design review?
N/A
PS Jenkins bot (ps-jenkins) wrote : | # |
PS Jenkins bot (ps-jenkins) wrote : | # |
FAILED: Continuous integration, rev:883
http://
Executed test runs:
UNSTABLE: http://
SUCCESS: http://
SUCCESS: http://
SUCCESS: http://
deb: http://
SUCCESS: http://
UNSTABLE: http://
SUCCESS: http://
deb: http://
SUCCESS: http://
Click here to trigger a rebuild:
http://
PS Jenkins bot (ps-jenkins) wrote : | # |
FAILED: Continuous integration, rev:883
http://
Executed test runs:
SUCCESS: http://
FAILURE: http://
SUCCESS: http://
SUCCESS: http://
deb: http://
SUCCESS: http://
SUCCESS: http://
SUCCESS: http://
deb: http://
SUCCESS: http://
Click here to trigger a rebuild:
http://
PS Jenkins bot (ps-jenkins) wrote : | # |
PASSED: Continuous integration, rev:883
http://
Executed test runs:
SUCCESS: http://
SUCCESS: http://
SUCCESS: http://
SUCCESS: http://
deb: http://
SUCCESS: http://
SUCCESS: http://
SUCCESS: http://
deb: http://
SUCCESS: http://
Click here to trigger a rebuild:
http://
Albert Astals Cid (aacid) wrote : | # |
It's failing for me locally
tsdgeos_
Xlib: extension "RANDR" missing on display ":99".
********* Start testing of qmltestrunner *********
Config: Using QtTest library 5.3.0, Qt 5.3.0
PASS : qmltestrunner:
PASS : qmltestrunner:
QWARN : qmltestrunner:
QWARN : qmltestrunner:
QWARN : qmltestrunner:
QWARN : qmltestrunner:
PASS : qmltestrunner:
PASS : qmltestrunner:
FAIL! : qmltestrunner:
Actual (): 0.9373503718221556
Expected (): 0.8870230941024013
Loc: [/home/
PASS : qmltestrunner:
Totals: 5 passed, 1 failed, 0 skipped
Michał Sawicz (saviq) wrote : | # |
PreviewZoomable
********* Start testing of qmltestrunner *********
Config: Using QtTest library 5.2.1, Qt 5.2.1
PASS : qmltestrunner:
FAIL! : qmltestrunner:
Actual (): default
Expected (): ready
Loc: [/home/
PASS : qmltestrunner:
Totals: 2 passed, 1 failed, 0 skipped
********* Finished testing of qmltestrunner *********
- 884. By Ying-Chun Liu
-
Merge trunk
[ Michal Hruby ]
* Updated scope tool to create proper config files after recent
libunity-scopes- api changes.
[ Michał Sawicz ]
* Refactor export_qmlfiles and export_qmlplugins to be more generic
and clean up installed mocks.
[ Albert Astals ]
* Remove empty dirs
* Set the tabbarmodel index as we do on real code It works better :D
(LP: #1317255)
[ Thomi Richards ]
* Use new import location for ProcessSearchError in process_helpers
script.
[ Andrea Cimitan ]
* Adds shadow for the carousel
[ Daniel d'Andrada ]
* Remove Revealer component It's not used anywhere anymore. It's been
replaced by DragHandle.
[ Andy Doan ]
* unlock_device: support more complex reboot/wait cycles Currently
this script only allows you to override how to "wait" on the device.
This changes the logic to also support how you go about rebooting
the device. This is handy for the ubuntu-emulator because adb-reboot
is not currently supported. However, we also have a more
sophisticated, fool-proof way we reboot/wait in the CI lab that
would be nice to take advantage of:
http://bazaar. launchpad. net/~ubuntu- test-case- dev/ubuntu- test-
cases/touch/view/ head:/scripts/ reboot- and-wait
[ CI bot ]
* Resync trunk
[ Michael Zanetti ]
* support appid:// entries in gsettings schema and make
findDesktopFile work with short-appid (LP: #1239750)
[ Antti Kaijanmäki ]
* Indicators/RootActionState : use g_variant_iter_loop to extract
icons.
[ Andrea Cimitan ]
* Improve padding in Text preview widget. (LP: #1316683)
[ CI bot ]
* Resync trunk
[ Nick Dedekind ]
* Removed binding loop from Unity.Indicators.MenuContentAc tivator
Change handler for QMLListProperty used by MenuContent.qml:
menuActivator.content[ index]. active If we're already asking for the
index, we know it exists already. No need to send a
changeNotification on an implied creation.
[ Josh Arenson ]
* Implements usage-style documentation for unity8 executable. Fixes
lp:1269282 (LP: #1269282)
[ Albert Astals ]
* Create specialized Card code in Javascript instead of having various
copied&pasted files (LP: #1297197)
[ Michał Sawicz ]
* Remove HUD from the bottom edge. Again. - 885. By Ying-Chun Liu
-
Fix ZoomableImage test fail. Use relative scale.
Fix PreviewZoomableImage fail. - 886. By Ying-Chun Liu
-
Fix indent.
PS Jenkins bot (ps-jenkins) wrote : | # |
FAILED: Continuous integration, rev:885
http://
Executed test runs:
FAILURE: http://
UNSTABLE: http://
FAILURE: http://
FAILURE: http://
FAILURE: http://
FAILURE: http://
Click here to trigger a rebuild:
http://
PS Jenkins bot (ps-jenkins) wrote : | # |
FAILED: Continuous integration, rev:886
http://
Executed test runs:
SUCCESS: http://
UNSTABLE: http://
SUCCESS: http://
SUCCESS: http://
deb: http://
SUCCESS: http://
SUCCESS: http://
SUCCESS: http://
deb: http://
SUCCESS: http://
Click here to trigger a rebuild:
http://
Albert Astals Cid (aacid) wrote : | # |
* Did you perform an exploratory manual test run of the code change and any related functionality?
Only tests changed, so no need for a test run other than running the tests.
* Did CI run pass?
No, some other known broken tests
Preview Diff
1 | === modified file 'tests/qmltests/Components/tst_ZoomableImage.qml' | |||
2 | --- tests/qmltests/Components/tst_ZoomableImage.qml 2014-04-25 14:48:36 +0000 | |||
3 | +++ tests/qmltests/Components/tst_ZoomableImage.qml 2014-05-23 14:07:40 +0000 | |||
4 | @@ -98,22 +98,23 @@ | |||
5 | 98 | // move mouse to center | 98 | // move mouse to center |
6 | 99 | mouseMove(zoomableImage, zoomableImage.width / 2, zoomableImage.height / 2); | 99 | mouseMove(zoomableImage, zoomableImage.width / 2, zoomableImage.height / 2); |
7 | 100 | 100 | ||
8 | 101 | var oldScale = image.scale; | ||
9 | 101 | // Test Zoom-in Zoom-out twice. | 102 | // Test Zoom-in Zoom-out twice. |
10 | 102 | for (var c=0; c<2; c++) { | 103 | for (var c=0; c<2; c++) { |
11 | 103 | // zoom in | 104 | // zoom in |
12 | 104 | for (var i=0; i<10; i++) { | 105 | for (var i=0; i<10; i++) { |
13 | 105 | mouseWheel(zoomableImage, zoomableImage.width / 2, zoomableImage.height / 2, 0, 10); | 106 | mouseWheel(zoomableImage, zoomableImage.width / 2, zoomableImage.height / 2, 0, 10); |
17 | 106 | tryCompare(image, "scale", 1.0 + (i + 1) * 0.1); | 107 | tryCompare(image, "scale", oldScale + (i + 1) * 0.1); |
18 | 107 | compare(flickable.contentWidth, lazyImage.width * image.scale); | 108 | compare(flickable.contentWidth, Math.max(lazyImage.width * image.scale, flickable.width)); |
19 | 108 | compare(flickable.contentHeight, lazyImage.height * image.scale); | 109 | compare(flickable.contentHeight, Math.max(lazyImage.height * image.scale, flickable.height)); |
20 | 109 | } | 110 | } |
21 | 110 | 111 | ||
22 | 111 | // zoom out | 112 | // zoom out |
23 | 112 | for (var i=0; i<10; i++) { | 113 | for (var i=0; i<10; i++) { |
24 | 113 | mouseWheel(zoomableImage, zoomableImage.width / 2, zoomableImage.height / 2, 0, -10); | 114 | mouseWheel(zoomableImage, zoomableImage.width / 2, zoomableImage.height / 2, 0, -10); |
28 | 114 | tryCompare(image, "scale", 2.0 - (i + 1) * 0.1); | 115 | tryCompare(image, "scale", oldScale + 1.0 - (i + 1) * 0.1); |
29 | 115 | compare(flickable.contentWidth, lazyImage.width * image.scale); | 116 | compare(flickable.contentWidth, Math.max(lazyImage.width * image.scale, flickable.width)); |
30 | 116 | compare(flickable.contentHeight, lazyImage.height * image.scale); | 117 | compare(flickable.contentHeight, Math.max(lazyImage.height * image.scale, flickable.height)); |
31 | 117 | } | 118 | } |
32 | 118 | } | 119 | } |
33 | 119 | } | 120 | } |
34 | @@ -123,16 +124,12 @@ | |||
35 | 123 | zoomable:false, | 124 | zoomable:false, |
36 | 124 | answer1: true, | 125 | answer1: true, |
37 | 125 | answer2: false, | 126 | answer2: false, |
41 | 126 | answer3: true, | 127 | answer3: true }, |
39 | 127 | answer4: 1.0, | ||
40 | 128 | answer5: 1.0 }, | ||
42 | 129 | { source:widgetData2["source"], | 128 | { source:widgetData2["source"], |
43 | 130 | zoomable:true, | 129 | zoomable:true, |
44 | 131 | answer1: false, | 130 | answer1: false, |
45 | 132 | answer2: true, | 131 | answer2: true, |
49 | 133 | answer3: false, | 132 | answer3: false } |
47 | 134 | answer4: 1.7740461882048026, | ||
48 | 135 | answer5: 1.0 } | ||
50 | 136 | ] | 133 | ] |
51 | 137 | } | 134 | } |
52 | 138 | 135 | ||
53 | @@ -163,7 +160,7 @@ | |||
54 | 163 | var y2End = zoomableImage.height * 5 / 6; | 160 | var y2End = zoomableImage.height * 5 / 6; |
55 | 164 | 161 | ||
56 | 165 | var oldScale = image.scale; | 162 | var oldScale = image.scale; |
58 | 166 | 163 | var newScale = -1; | |
59 | 167 | // move mouse to center | 164 | // move mouse to center |
60 | 168 | mouseMove(zoomableImage, zoomableImage.width / 2, zoomableImage.height / 2); | 165 | mouseMove(zoomableImage, zoomableImage.width / 2, zoomableImage.height / 2); |
61 | 169 | 166 | ||
62 | @@ -172,20 +169,25 @@ | |||
63 | 172 | wait(3000); // have to delay between two consequent pinch event. | 169 | wait(3000); // have to delay between two consequent pinch event. |
64 | 173 | // pinch zoom-in | 170 | // pinch zoom-in |
65 | 174 | touchPinch(zoomableImage, x1Start, y1Start, x1End, y1End, x2Start, y2Start, x2End, y2End); | 171 | touchPinch(zoomableImage, x1Start, y1Start, x1End, y1End, x2Start, y2Start, x2End, y2End); |
66 | 172 | waitForRendering(image); | ||
67 | 175 | 173 | ||
70 | 176 | tryCompare(image, "scale", data.answer4); | 174 | if (newScale == -1) { |
71 | 177 | var newScale = image.scale; | 175 | newScale = image.scale; |
72 | 176 | } | ||
73 | 177 | tryCompare(image, "scale", newScale); | ||
74 | 178 | compare(newScale == oldScale, data.answer1, "scale factor not equal: "+ oldScale + "=?" + newScale); | 178 | compare(newScale == oldScale, data.answer1, "scale factor not equal: "+ oldScale + "=?" + newScale); |
75 | 179 | compare(newScale > oldScale, data.answer2, "scale factor didn't changed"); | 179 | compare(newScale > oldScale, data.answer2, "scale factor didn't changed"); |
76 | 180 | compare(signalSpy.count == 0, data.answer3, "scale signal count error"); | 180 | compare(signalSpy.count == 0, data.answer3, "scale signal count error"); |
80 | 181 | compare(newScale, data.answer4, "scale factor error"); | 181 | compare(image.scale, newScale, "scale factor error"); |
81 | 182 | compare(flickable.contentWidth, lazyImage.width * image.scale); | 182 | compare(flickable.contentWidth, Math.max(lazyImage.width * image.scale, flickable.width)); |
82 | 183 | compare(flickable.contentHeight, lazyImage.height * image.scale); | 183 | compare(flickable.contentHeight, Math.max(lazyImage.height * image.scale, flickable.height)); |
83 | 184 | 184 | ||
84 | 185 | wait(3000); // have to delay between two consequent pinch event. | 185 | wait(3000); // have to delay between two consequent pinch event. |
85 | 186 | // pinch zoom-out | 186 | // pinch zoom-out |
86 | 187 | touchPinch(zoomableImage, x1End, y1End, x1Start, y1Start, x2End, y2End, x2Start, y2Start); | 187 | touchPinch(zoomableImage, x1End, y1End, x1Start, y1Start, x2End, y2End, x2Start, y2Start); |
88 | 188 | tryCompare(image, "scale", data.answer5); | 188 | tryCompare(image, "scale", oldScale); |
89 | 189 | compare(flickable.contentWidth, Math.max(lazyImage.width * image.scale, flickable.width)); | ||
90 | 190 | compare(flickable.contentHeight, Math.max(lazyImage.height * image.scale, flickable.height)); | ||
91 | 189 | } | 191 | } |
92 | 190 | } | 192 | } |
93 | 191 | } | 193 | } |
94 | 192 | 194 | ||
95 | === modified file 'tests/qmltests/Dash/Previews/tst_PreviewZoomableImage.qml' | |||
96 | --- tests/qmltests/Dash/Previews/tst_PreviewZoomableImage.qml 2014-04-08 12:38:12 +0000 | |||
97 | +++ tests/qmltests/Dash/Previews/tst_PreviewZoomableImage.qml 2014-05-23 14:07:40 +0000 | |||
98 | @@ -26,14 +26,14 @@ | |||
99 | 26 | color: "lightgrey" | 26 | color: "lightgrey" |
100 | 27 | 27 | ||
101 | 28 | property var widgetData0: { | 28 | property var widgetData0: { |
102 | 29 | "source": "" | ||
103 | 30 | } | ||
104 | 31 | |||
105 | 32 | property var widgetData1: { | ||
106 | 33 | "source": Qt.resolvedUrl("../artwork/checkers.png"), | 29 | "source": Qt.resolvedUrl("../artwork/checkers.png"), |
107 | 34 | "zoomable": false | 30 | "zoomable": false |
108 | 35 | } | 31 | } |
109 | 36 | 32 | ||
110 | 33 | property var widgetData1: { | ||
111 | 34 | "source": "" | ||
112 | 35 | } | ||
113 | 36 | |||
114 | 37 | PreviewZoomableImage { | 37 | PreviewZoomableImage { |
115 | 38 | id: zoomableImage | 38 | id: zoomableImage |
116 | 39 | anchors.fill: parent | 39 | anchors.fill: parent |
117 | @@ -49,11 +49,13 @@ | |||
118 | 49 | 49 | ||
119 | 50 | zoomableImage.widgetData = widgetData0; | 50 | zoomableImage.widgetData = widgetData0; |
120 | 51 | waitForRendering(zoomableImage); | 51 | waitForRendering(zoomableImage); |
121 | 52 | waitForRendering(image); | ||
122 | 53 | tryCompare(image, "imageState", "ready"); | ||
123 | 54 | |||
124 | 55 | zoomableImage.widgetData = widgetData1; | ||
125 | 56 | waitForRendering(zoomableImage); | ||
126 | 57 | waitForRendering(image); | ||
127 | 52 | tryCompare(image, "imageState", "default"); | 58 | tryCompare(image, "imageState", "default"); |
128 | 53 | |||
129 | 54 | zoomableImage.widgetData = widgetData1; | ||
130 | 55 | waitForRendering(zoomableImage); | ||
131 | 56 | tryCompare(image, "imageState", "ready"); | ||
132 | 57 | } | 59 | } |
133 | 58 | } | 60 | } |
134 | 59 | } | 61 | } |
FAILED: Continuous integration, rev:883 jenkins. qa.ubuntu. com/job/ unity8- ci/2931/ jenkins. qa.ubuntu. com/job/ generic- deb-autopilot- utopic- touch/72 jenkins. qa.ubuntu. com/job/ unity-phablet- qmluitests- trusty/ 1795/console jenkins. qa.ubuntu. com/job/ unity8- utopic- amd64-ci/ 25 jenkins. qa.ubuntu. com/job/ unity8- utopic- armhf-ci/ 25 jenkins. qa.ubuntu. com/job/ unity8- utopic- armhf-ci/ 25/artifact/ work/output/ *zip*/output. zip jenkins. qa.ubuntu. com/job/ unity8- utopic- i386-ci/ 25 jenkins. qa.ubuntu. com/job/ generic- deb-autopilot- runner- mako/576 jenkins. qa.ubuntu. com/job/ generic- mediumtests- builder- utopic- armhf/178 jenkins. qa.ubuntu. com/job/ generic- mediumtests- builder- utopic- armhf/178/ artifact/ work/output/ *zip*/output. zip s-jenkins. ubuntu- ci:8080/ job/touch- flash-device/ 6896
http://
Executed test runs:
SUCCESS: http://
FAILURE: http://
SUCCESS: http://
SUCCESS: http://
deb: http://
SUCCESS: http://
SUCCESS: http://
SUCCESS: http://
deb: http://
SUCCESS: http://
Click here to trigger a rebuild: s-jenkins. ubuntu- ci:8080/ job/unity8- ci/2931/ rebuild
http://