Merge lp:~elopio/ubuntu-clock-app/qmlscene_launch into lp:ubuntu-clock-app/saucy

Proposed by Leo Arias
Status: Merged
Approved by: Nekhelesh Ramananthan
Approved revision: 259
Merged at revision: 257
Proposed branch: lp:~elopio/ubuntu-clock-app/qmlscene_launch
Merge into: lp:ubuntu-clock-app/saucy
Diff against target: 64 lines (+10/-12)
1 file modified
tests/autopilot/ubuntu_clock_app/tests/__init__.py (+10/-12)
To merge this branch: bzr merge lp:~elopio/ubuntu-clock-app/qmlscene_launch
Reviewer Review Type Date Requested Status
Ubuntu Phone Apps Jenkins Bot continuous-integration Approve
Nicholas Skaggs (community) Approve
Christopher Lee (community) Approve
Review via email: mp+193842@code.launchpad.net

Commit message

Use the test case class and methods from ubuntuuitoolkit autopilot base module.

To post a comment you must log in.
259. By Leo Arias

Fixed the import order.

Revision history for this message
Christopher Lee (veebers) wrote :

LGTM

review: Approve
Revision history for this message
Nicholas Skaggs (nskaggs) wrote :

veebers beat me :-)

review: Approve
Revision history for this message
Ubuntu Phone Apps Jenkins Bot (ubuntu-phone-apps-jenkins-bot) :
review: Approve (continuous-integration)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'tests/autopilot/ubuntu_clock_app/tests/__init__.py'
2--- tests/autopilot/ubuntu_clock_app/tests/__init__.py 2013-10-09 08:20:41 +0000
3+++ tests/autopilot/ubuntu_clock_app/tests/__init__.py 2013-11-04 20:40:36 +0000
4@@ -24,26 +24,24 @@
5 import shutil
6 import logging
7
8-from autopilot.input import Mouse, Touch, Pointer
9+from autopilot import input
10 from autopilot.platform import model
11-from autopilot.testcase import AutopilotTestCase
12-from ubuntuuitoolkit import emulators as toolkit_emulators
13+from ubuntuuitoolkit import (
14+ base,
15+ emulators as toolkit_emulators
16+)
17+
18 from ubuntu_clock_app import emulators
19
20 logger = logging.getLogger(__name__)
21
22
23-class ClockAppTestCase(AutopilotTestCase):
24+class ClockAppTestCase(base.UbuntuUIToolkitAppTestCase):
25
26 """A common test case class that provides several useful methods for
27 calendar-app tests.
28
29 """
30- if model() == 'Desktop':
31- scenarios = [('with mouse', dict(input_device_class=Mouse))]
32- else:
33- scenarios = [('with touch', dict(input_device_class=Touch))]
34-
35 local_location = "../../ubuntu-clock-app.qml"
36 installed_location = "/usr/share/ubuntu-clock-app/ubuntu-clock-app.qml"
37 sqlite_dir = os.path.expanduser(
38@@ -51,8 +49,8 @@
39 backup_dir = sqlite_dir + ".backup"
40
41 def setUp(self):
42- self.pointing_device = Pointer(self.input_device_class.create())
43 super(ClockAppTestCase, self).setUp()
44+ self.pointing_device = input.Pointer(self.input_device_class.create())
45
46 #backup and wipe db's before testing
47 self.temp_move_sqlite_db()
48@@ -74,14 +72,14 @@
49
50 def launch_test_local(self):
51 self.app = self.launch_test_application(
52- "qmlscene",
53+ base.get_qmlscene_launch_command(),
54 self.local_location,
55 app_type='qt',
56 emulator_base=toolkit_emulators.UbuntuUIToolkitEmulatorBase)
57
58 def launch_test_installed(self):
59 self.app = self.launch_test_application(
60- "qmlscene",
61+ base.get_qmlscene_launch_command(),
62 self.installed_location,
63 "--desktop_file_hint=/usr/share/applications/"
64 "ubuntu-clock-app.desktop",

Subscribers

People subscribed via source and target branches