Merge lp:~canonical-platform-qa/ubuntu-calendar-app/fix1341681-new_toolkit_namespace into lp:ubuntu-calendar-app

Proposed by Leo Arias
Status: Merged
Approved by: Nicholas Skaggs
Approved revision: 379
Merged at revision: 384
Proposed branch: lp:~canonical-platform-qa/ubuntu-calendar-app/fix1341681-new_toolkit_namespace
Merge into: lp:ubuntu-calendar-app
Diff against target: 169 lines (+19/-29)
2 files modified
tests/autopilot/calendar_app/emulators.py (+15/-25)
tests/autopilot/calendar_app/tests/__init__.py (+4/-4)
To merge this branch: bzr merge lp:~canonical-platform-qa/ubuntu-calendar-app/fix1341681-new_toolkit_namespace
Reviewer Review Type Date Requested Status
Ubuntu Phone Apps Jenkins Bot continuous-integration Approve
Omer Akram (community) Approve
Canonical Platform QA Team Pending
Review via email: mp+229340@code.launchpad.net

Commit message

Use the new toolkit namespace for autopilot tests.

To post a comment you must log in.
Revision history for this message
Ubuntu Phone Apps Jenkins Bot (ubuntu-phone-apps-jenkins-bot) wrote :
review: Approve (continuous-integration)
Revision history for this message
Ubuntu Phone Apps Jenkins Bot (ubuntu-phone-apps-jenkins-bot) wrote :
review: Approve (continuous-integration)
Revision history for this message
Omer Akram (om26er) wrote :

Code is clean, thank you.

review: Approve
Revision history for this message
Ubuntu Phone Apps Jenkins Bot (ubuntu-phone-apps-jenkins-bot) wrote :
review: Needs Fixing (continuous-integration)
Revision history for this message
Ubuntu Phone Apps Jenkins Bot (ubuntu-phone-apps-jenkins-bot) wrote :
review: Needs Fixing (continuous-integration)
Revision history for this message
Ubuntu Phone Apps Jenkins Bot (ubuntu-phone-apps-jenkins-bot) wrote :
review: Needs Fixing (continuous-integration)
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/calendar_app/emulators.py'
2--- tests/autopilot/calendar_app/emulators.py 2014-07-31 19:39:04 +0000
3+++ tests/autopilot/calendar_app/emulators.py 2014-08-03 01:56:50 +0000
4@@ -23,11 +23,6 @@
5 from dateutil import tz
6
7 import ubuntuuitoolkit
8-from ubuntuuitoolkit._custom_proxy_objects import _flickable
9-from ubuntuuitoolkit import (
10- emulators as toolkit_emulators,
11- pickers
12-)
13
14 from calendar_app import data
15
16@@ -40,14 +35,7 @@
17 """Exception raised when there are problems with the Calendar."""
18
19
20-# for now we are borrowing the textfield helper for the textarea
21-# once the toolkit has a textarea helper this should be removed
22-# https://bugs.launchpad.net/ubuntu-ui-toolkit/+bug/1327354
23-class TextArea(toolkit_emulators.TextField):
24- """Autopilot helper for the TextArea component."""
25-
26-
27-class MainView(toolkit_emulators.MainView):
28+class MainView(ubuntuuitoolkit.MainView):
29
30 """An emulator that makes it easy to interact with the calendar-app."""
31
32@@ -127,7 +115,7 @@
33 else:
34 mode_value = 'Years|Months|Days'
35 picker = self.wait_select_single(
36- pickers.DatePicker, mode=mode_value, visible=True)
37+ ubuntuuitoolkit.pickers.DatePicker, mode=mode_value, visible=True)
38 if mode_value == 'Hours|Minutes':
39 picker.pick_time(value)
40 else:
41@@ -221,22 +209,22 @@
42 return local
43
44
45-class YearView(toolkit_emulators.UbuntuUIToolkitEmulatorBase):
46+class YearView(ubuntuuitoolkit.UbuntuUIToolkitCustomProxyObjectBase):
47
48 """Autopilot helper for the Year View page."""
49
50
51-class WeekView(toolkit_emulators.UbuntuUIToolkitEmulatorBase):
52+class WeekView(ubuntuuitoolkit.UbuntuUIToolkitCustomProxyObjectBase):
53
54 """Autopilot helper for the Week View page."""
55
56
57-class MonthView(toolkit_emulators.UbuntuUIToolkitEmulatorBase):
58+class MonthView(ubuntuuitoolkit.UbuntuUIToolkitCustomProxyObjectBase):
59
60 """Autopilot helper for the Year View page."""
61
62
63-class DayView(toolkit_emulators.UbuntuUIToolkitEmulatorBase):
64+class DayView(ubuntuuitoolkit.UbuntuUIToolkitCustomProxyObjectBase):
65
66 """Autopilot helper for the Day View page."""
67
68@@ -369,7 +357,7 @@
69 return day_header
70
71
72-class EventBubble(toolkit_emulators.UbuntuUIToolkitEmulatorBase):
73+class EventBubble(ubuntuuitoolkit.UbuntuUIToolkitCustomProxyObjectBase):
74
75 """Autopiot helper for the Event Bubble items."""
76
77@@ -410,7 +398,7 @@
78
79 # override toolkit helper to
80 # workaround bug https://bugs.launchpad.net/ubuntu-ui-toolkit/+bug/1343916
81-class QQuickFlickable(_flickable.QQuickFlickable):
82+class QQuickFlickable(ubuntuuitoolkit.QQuickFlickable):
83
84 def _slow_drag(self, start_x, stop_x, start_y, stop_y):
85 rate = (self.flickDeceleration + 250) / 350
86@@ -418,7 +406,7 @@
87 self.pointing_device.click()
88
89
90-class NewEvent(toolkit_emulators.UbuntuUIToolkitEmulatorBase):
91+class NewEvent(ubuntuuitoolkit.UbuntuUIToolkitCustomProxyObjectBase):
92
93 """Autopilot helper for the New Event page."""
94
95@@ -478,7 +466,8 @@
96 self._ensure_visible_and_write(description_text_area, value)
97
98 def _get_description_text_area(self):
99- return self.select_single(TextArea, objectName='eventDescriptionInput')
100+ return self.select_single(
101+ ubuntuuitoolkit.TextArea, objectName='eventDescriptionInput')
102
103 def _fill_location(self, value):
104 self._ensure_entry_field_visible_and_write('eventLocationInput', value)
105@@ -532,12 +521,12 @@
106 self.pointing_device.click_object(save_button)
107
108
109-class NewEventEntryField(toolkit_emulators.TextField):
110+class NewEventEntryField(ubuntuuitoolkit.TextField):
111
112 """Autopilot helper for the NewEventEntryField component."""
113
114
115-class EventDetails(toolkit_emulators.UbuntuUIToolkitEmulatorBase):
116+class EventDetails(ubuntuuitoolkit.UbuntuUIToolkitCustomProxyObjectBase):
117
118 """Autopilot helper for the Event Details page."""
119
120@@ -593,7 +582,8 @@
121 return guests
122
123
124-class DeleteConfirmationDialog(toolkit_emulators.UbuntuUIToolkitEmulatorBase):
125+class DeleteConfirmationDialog(
126+ ubuntuuitoolkit.UbuntuUIToolkitCustomProxyObjectBase):
127
128 """Autopilot helper for the Delete Confirmation dialog."""
129
130
131=== modified file 'tests/autopilot/calendar_app/tests/__init__.py'
132--- tests/autopilot/calendar_app/tests/__init__.py 2014-06-26 18:10:28 +0000
133+++ tests/autopilot/calendar_app/tests/__init__.py 2014-08-03 01:56:50 +0000
134@@ -28,9 +28,9 @@
135 from autopilot.testcase import AutopilotTestCase
136 from autopilot import logging as autopilot_logging
137
138+import ubuntuuitoolkit
139 from ubuntuuitoolkit import (
140 base,
141- emulators as toolkit_emulators,
142 fixture_setup as toolkit_fixtures
143 )
144
145@@ -83,7 +83,7 @@
146 base.get_qmlscene_launch_command(),
147 self.local_location_qml,
148 app_type='qt',
149- emulator_base=toolkit_emulators.UbuntuUIToolkitEmulatorBase)
150+ emulator_base=ubuntuuitoolkit.UbuntuUIToolkitCustomProxyObjectBase)
151
152 @autopilot_logging.log_action(logger.info)
153 def launch_test_installed(self):
154@@ -91,13 +91,13 @@
155 base.get_qmlscene_launch_command(),
156 self.installed_location_qml,
157 app_type='qt',
158- emulator_base=toolkit_emulators.UbuntuUIToolkitEmulatorBase)
159+ emulator_base=ubuntuuitoolkit.UbuntuUIToolkitCustomProxyObjectBase)
160
161 @autopilot_logging.log_action(logger.info)
162 def launch_test_click(self):
163 return self.launch_click_package(
164 "com.ubuntu.calendar",
165- emulator_base=toolkit_emulators.UbuntuUIToolkitEmulatorBase)
166+ emulator_base=ubuntuuitoolkit.UbuntuUIToolkitCustomProxyObjectBase)
167
168 def _copy_xauthority_file(self, directory):
169 """ Copy .Xauthority file to directory, if it exists in /home

Subscribers

People subscribed via source and target branches

to status/vote changes: