Merge lp:~renatofilho/mediaplayer-app/add-gst-libav into lp:mediaplayer-app

Proposed by Renato Araujo Oliveira Filho
Status: Rejected
Rejected by: Renato Araujo Oliveira Filho
Proposed branch: lp:~renatofilho/mediaplayer-app/add-gst-libav
Merge into: lp:mediaplayer-app
Diff against target: 307 lines (+78/-68)
6 files modified
debian/control (+2/-1)
src/qml/player.qml (+1/-0)
tests/autopilot/mediaplayer_app/emulators/main_window.py (+35/-2)
tests/autopilot/mediaplayer_app/tests/__init__.py (+2/-5)
tests/autopilot/mediaplayer_app/tests/test_player.py (+9/-21)
tests/autopilot/mediaplayer_app/tests/test_player_with_video.py (+29/-39)
To merge this branch: bzr merge lp:~renatofilho/mediaplayer-app/add-gst-libav
Reviewer Review Type Date Requested Status
PS Jenkins bot continuous-integration Needs Fixing
Ubuntu Phablet Team Pending
Review via email: mp+193604@code.launchpad.net

Commit message

Added gstreamer1.0-libav as dep for i386 and amd64 arch.

To post a comment you must log in.
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Needs Fixing (continuous-integration)
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Needs Fixing (continuous-integration)
141. By Renato Araujo Oliveira Filho

Changed autopilot package arch.

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

FAILED: Continuous integration, rev:141
http://jenkins.qa.ubuntu.com/job/mediaplayer-app-ci/149/
Executed test runs:
    UNSTABLE: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-trusty/291
    FAILURE: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-trusty-touch/281/console
    SUCCESS: http://jenkins.qa.ubuntu.com/job/mediaplayer-app-trusty-amd64-ci/5
    SUCCESS: http://jenkins.qa.ubuntu.com/job/mediaplayer-app-trusty-armhf-ci/5
        deb: http://jenkins.qa.ubuntu.com/job/mediaplayer-app-trusty-armhf-ci/5/artifact/work/output/*zip*/output.zip
    SUCCESS: http://jenkins.qa.ubuntu.com/job/mediaplayer-app-trusty-i386-ci/5
    UNSTABLE: http://jenkins.qa.ubuntu.com/job/autopilot-testrunner-otto-trusty/275
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-trusty-amd64/291
        deb: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-trusty-amd64/291/artifact/work/output/*zip*/output.zip
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-trusty-armhf/281
        deb: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-trusty-armhf/281/artifact/work/output/*zip*/output.zip
    FAILURE: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-runner-maguro/2898/console
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-runner-mako/2949
    SUCCESS: http://10.97.0.26:8080/job/touch-flash-device/842
    SUCCESS: http://10.97.0.26:8080/job/touch-flash-device/843

Click here to trigger a rebuild:
http://10.97.0.26:8080/job/mediaplayer-app-ci/149/rebuild

review: Needs Fixing (continuous-integration)

Unmerged revisions

141. By Renato Araujo Oliveira Filho

Changed autopilot package arch.

140. By Renato Araujo Oliveira Filho

Added gstreamer1.0-libav as dep for i386 and amd64 arch.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'debian/control'
2--- debian/control 2013-10-14 21:48:26 +0000
3+++ debian/control 2013-11-01 15:09:37 +0000
4@@ -37,10 +37,11 @@
5 A QML Media player service used by Ubuntu shell to play video sources.
6
7 Package: mediaplayer-app-autopilot
8-Architecture: all
9+Architecture: any
10 Depends: ${misc:Depends},
11 ${shlibs:Depends},
12 libautopilot-qt,
13+ gstreamer1.0-libav[i386 amd64],
14 libqt5test5,
15 libqt5widgets5,
16 mediaplayer-app (>= ${source:Version}),
17
18=== modified file 'src/qml/player.qml'
19--- src/qml/player.qml 2013-10-15 22:50:12 +0000
20+++ src/qml/player.qml 2013-11-01 15:09:37 +0000
21@@ -60,6 +60,7 @@
22
23 Popups.Dialog {
24 id: dialogue
25+ objectName: "noMediaDialog"
26
27 title: i18n.tr("Error")
28 text: i18n.tr("No video selected to play. Connect your phone to your computer to transfer videos to the phone. Then select video from Videos lens.")
29
30=== modified file 'tests/autopilot/mediaplayer_app/emulators/main_window.py'
31--- tests/autopilot/mediaplayer_app/emulators/main_window.py 2013-05-27 11:23:52 +0000
32+++ tests/autopilot/mediaplayer_app/emulators/main_window.py 2013-11-01 15:09:37 +0000
33@@ -16,5 +16,38 @@
34 """Get the main QML view"""
35 return self.app.select_single("QQuickView")
36
37- def get_object(self, typeName, name):
38- return self.app.select_single(typeName, objectName=name)
39+ def get_controls(self):
40+ return self.app.select_single("Controls", objectName="controls")
41+
42+ def get_video_area(self):
43+ return self.app.select_single("VideoPlayer", objectName="player")
44+
45+ def get_toolbar(self):
46+ return self.app.select_single("GenericToolbar", objectName="toolbar")
47+
48+ def get_playback_button(self):
49+ return self.app.select_single("IconButton", objectName="Controls.PlayBackButton")
50+
51+ def get_player(self):
52+ return self.app.select_single("VideoPlayer", objectName="player")
53+
54+ def get_scene_selector(self):
55+ return self.app.select_single("SceneSelector", objectName="Controls.SceneSelector")
56+
57+ def get_slider(self):
58+ return self.app.select_single("Slider", objectName="TimeLine.Slider")
59+
60+ def get_timeline(self):
61+ return self.app.select_single("TimeLine", objectName="TimeLine")
62+
63+ def get_scene_0(self):
64+ return self.app.select_single("SceneFrame", objectName="SceneSelector.Scene0")
65+
66+ def get_scene_2(self):
67+ return self.app.select_single("SceneFrame", objectName="SceneSelector.Scene2")
68+
69+ def get_time_label(self):
70+ return self.app.select_single("Label", objectName="TimeLine.TimeLabel")
71+
72+ def get_no_video_dialog(self):
73+ return self.app.select_single("Dialog", objectName="noMediaDialog")
74
75=== modified file 'tests/autopilot/mediaplayer_app/tests/__init__.py'
76--- tests/autopilot/mediaplayer_app/tests/__init__.py 2013-05-27 11:23:52 +0000
77+++ tests/autopilot/mediaplayer_app/tests/__init__.py 2013-11-01 15:09:37 +0000
78@@ -7,7 +7,6 @@
79
80 """mediaplayer-app autopilot tests."""
81
82-from os import remove
83 import os.path
84 import os
85
86@@ -26,11 +25,9 @@
87 """
88
89 if model() == 'Desktop':
90- scenarios = [
91- ('with mouse', dict(input_device_class=Mouse))]
92+ scenarios = [('with mouse', dict(input_device_class=Mouse))]
93 else:
94- scenarios = [
95- ('with touch', dict(input_device_class=Touch))]
96+ scenarios = [('with touch', dict(input_device_class=Touch))]
97
98 def setUp(self):
99 self.pointing_device = Pointer(self.input_device_class.create())
100
101=== modified file 'tests/autopilot/mediaplayer_app/tests/test_player.py'
102--- tests/autopilot/mediaplayer_app/tests/test_player.py 2013-05-27 11:23:52 +0000
103+++ tests/autopilot/mediaplayer_app/tests/test_player.py 2013-11-01 15:09:37 +0000
104@@ -14,11 +14,6 @@
105
106 from mediaplayer_app.tests import MediaplayerAppTestCase
107
108-import unittest
109-import time
110-import os
111-from os import path
112-
113
114 class TestPlayer(MediaplayerAppTestCase):
115 """Tests the main media player features"""
116@@ -34,19 +29,12 @@
117 def tearDown(self):
118 super(TestPlayer, self).tearDown()
119
120- """ Test if the toolbar appears with mouse click over the video area """
121- def test_controls_visibility(self):
122- controls = self.main_window.get_object("Controls", "controls")
123-
124- """ The toolbar is invisible by default """
125- self.assertProperty(controls, visible=False)
126-
127- """ Toolbar must apper when clicked in the video area """
128- video_area = self.main_window.get_object("VideoPlayer", "player")
129- self.pointing_device.move_to_object(video_area)
130- self.pointing_device.click()
131- self.assertProperty(controls, visible=True)
132-
133- """ Toolbar must disappear when clicked in the video area again """
134- self.pointing_device.click()
135- self.assertProperty(controls, visible=True)
136+ def test_no_video_dialog_visible(self):
137+ """ Makes sure 'No Video' dialog appears if the meidaplayer is opened
138+ without a video file argument.
139+
140+ """
141+
142+ dialog = self.main_window.get_no_video_dialog()
143+ self.assertThat(dialog.visible, Eventually(Equals(True)))
144+
145
146=== modified file 'tests/autopilot/mediaplayer_app/tests/test_player_with_video.py'
147--- tests/autopilot/mediaplayer_app/tests/test_player_with_video.py 2013-09-25 21:19:34 +0000
148+++ tests/autopilot/mediaplayer_app/tests/test_player_with_video.py 2013-11-01 15:09:37 +0000
149@@ -30,64 +30,60 @@
150 self.assertThat(
151 self.main_window.get_qml_view().visible, Eventually(Equals(True)))
152 # wait video player start
153- player = self.main_window.get_object("VideoPlayer", "player")
154+ player = self.main_window.get_player()
155 self.assertThat(player.playing, Eventually(Equals(True)))
156
157 def tearDown(self):
158 super(TestPlayerWithVideo, self).tearDown()
159
160 def show_controls(self):
161- video_area = self.main_window.get_object("VideoPlayer", "player")
162- self.pointing_device.move_to_object(video_area)
163- self.pointing_device.click()
164- toolbar = self.main_window.get_object("GenericToolbar", "toolbar")
165+ video_area = self.main_window.get_video_area()
166+ self.pointing_device.click_object(video_area)
167+ toolbar = self.main_window.get_toolbar()
168 self.assertThat(toolbar.ready, Eventually(Equals(True)))
169
170 def pause_video(self):
171- playback_buttom = self.main_window.get_object("IconButton", "Controls.PlayBackButton")
172- self.pointing_device.move_to_object(playback_buttom)
173- self.pointing_device.click()
174+ playback_button = self.main_window.get_playback_button()
175+ self.pointing_device.click_object(playback_button)
176
177- def test_playback_buttom_states(self):
178+ def test_playback_button_states(self):
179 self.show_controls()
180
181- playback_buttom = self.main_window.get_object("IconButton", "Controls.PlayBackButton")
182- player = self.main_window.get_object("VideoPlayer", "player")
183+ playback_button = self.main_window.get_playback_button()
184+ player = self.main_window.get_player()
185
186 """ Default state after load the video is playing and with pause
187 icon.
188 """
189 self.assertProperty(player, playing=True, paused=False)
190- self.assertProperty(playback_buttom, icon="pause")
191+ self.assertProperty(playback_button, icon="pause")
192
193- self.pointing_device.move_to_object(playback_buttom)
194- self.pointing_device.click()
195+ self.pointing_device.click_object(playback_button)
196
197 """ First click must pause the video, change playing state and show
198 play icon. """
199 self.assertProperty(player, playing=False, paused=True)
200- self.assertProperty(playback_buttom, icon="play")
201+ self.assertProperty(playback_button, icon="play")
202
203 self.pointing_device.click()
204
205 """ Second click should change the state to playing again """
206 self.assertProperty(player, playing=True, paused=False)
207- self.assertProperty(playback_buttom, icon="pause")
208+ self.assertProperty(playback_button, icon="pause")
209
210 @skip("New backend work needed. bug 1231147")
211 def test_scene_selector_visibility(self):
212 self.show_controls()
213 self.pause_video()
214
215- scene_selector = self.main_window.get_object("SceneSelector", "Controls.SceneSelector")
216- slider = self.main_window.get_object("Slider", "TimeLine.Slider")
217+ scene_selector = self.main_window.get_scene_selector()
218+ slider = self.main_window.get_slider()
219
220 """ Default state is hide """
221 self.assertProperty(scene_selector, visible=False)
222
223 """ Scene selector must apper when clicking int the slider handler """
224- self.pointing_device.move_to_object(slider)
225- self.pointing_device.click()
226+ self.pointing_device.click_object(slider)
227 self.assertProperty(scene_selector, visible=True)
228
229 """ click again must dismiss the scene selector """
230@@ -99,17 +95,16 @@
231 self.show_controls()
232 self.pause_video()
233
234- slider = self.main_window.get_object("Slider", "TimeLine.Slider")
235- time_line = self.main_window.get_object("TimeLine", "TimeLine")
236- selector = self.main_window.get_object("SceneSelector", "Controls.SceneSelector")
237+ slider = self.main_window.get_slider()
238+ time_line = self.main_window.get_timeline()
239+ selector = self.main_window.get_scene_selector()
240 self.assertThat(selector.count, Eventually(GreaterThan(3)))
241
242 """ Show scene selector """
243- self.pointing_device.move_to_object(slider)
244- self.pointing_device.click()
245+ self.pointing_device.click_object(slider)
246
247 """ Make sure that the scenes are in correct place """
248- scene_0 = self.main_window.get_object("SceneFrame", "SceneSelector.Scene0")
249+ scene_0 = self.main_window.get_scene_0()
250 selectorRect = selector.globalRect
251 self.pointing_device.drag(
252 selectorRect[0], selectorRect[1] + selectorRect[3] / 2,
253@@ -118,10 +113,9 @@
254 self.assertThat(scene_0.x, Eventually(Equals(0)))
255
256 """ Click in the second scene """
257- scene_2 = self.main_window.get_object("SceneFrame", "SceneSelector.Scene2")
258+ scene_2 = self.main_window.get_scene_2()
259 self.assertThat(scene_2.ready, Eventually(Equals(True)))
260- self.pointing_device.move_to_object(scene_2)
261- self.pointing_device.click()
262+ self.pointing_device.click_object(scene_2)
263 self.assertThat(selector.currentIndex, Eventually(Equals(2)))
264 self.assertProperty(time_line, value=1.107)
265
266@@ -130,35 +124,31 @@
267 self.show_controls()
268 self.pause_video()
269
270- time_line = self.main_window.get_object("Slider", "TimeLine.Slider")
271- time_label = self.main_window.get_object("Label", "TimeLine.TimeLabel")
272- scene_selector = self.main_window.get_object("SceneSelector", "Controls.SceneSelector")
273+ time_line = self.main_window.get_slider()
274+ time_label = self.main_window.get_time_label()
275
276 """ Seek to the midle of the movie """
277 self.pointing_device.click_object(time_line)
278- self.assertThat(scene_selector.opacity, Eventually(Equals(1)))
279
280 """ Time label must show the current video time (diff from zero or empty) """
281 self.assertNotEqual(time_label.text, "00:00:00")
282 self.assertNotEqual(time_label.text, "")
283
284 """ Click in the label to change the state """
285- self.pointing_device.move_to_object(time_label)
286- self.pointing_device.click()
287+ self.pointing_device.click_object(time_label)
288
289 """ After the click the label must show the remaning time (with '-' signal) """
290 self.assertEqual(time_label.text[0:1], "-")
291
292 @skipIf(model() == 'Nexus 4' or model() == 'Galaxy Nexus', 'Screen width not enough for seekbar')
293 def test_show_controls_at_end(self):
294- time_line = self.main_window.get_object("Slider", "TimeLine.Slider")
295
296 """ wait for video ends and control appears"""
297- time_label = self.main_window.get_object("Label", "TimeLine.TimeLabel")
298+ time_label = self.main_window.get_time_label()
299
300 """ avoid the test fails due the timeout """
301 self.assertThat(time_label.text, Eventually(Equals("00:00:25"), timeout=35))
302-
303- controls = self.main_window.get_object("Controls", "controls")
304+
305+ controls = self.main_window.get_controls()
306 self.assertProperty(controls, visible=False)
307 self.assertThat(controls.visible, Eventually(Equals(True)))

Subscribers

People subscribed via source and target branches