Merge lp:~nskaggs/ubuntu-ui-toolkit/fix-aphelper-emulator-warning into lp:ubuntu-ui-toolkit/staging

Proposed by Nicholas Skaggs
Status: Merged
Approved by: Zoltan Balogh
Approved revision: 1067
Merged at revision: 1195
Proposed branch: lp:~nskaggs/ubuntu-ui-toolkit/fix-aphelper-emulator-warning
Merge into: lp:ubuntu-ui-toolkit/staging
Diff against target: 298 lines (+30/-30)
12 files modified
tests/autopilot/ubuntuuitoolkit/__init__.py (+0/-2)
tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_checkbox.py (+1/-1)
tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_common.py (+4/-4)
tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_header.py (+4/-4)
tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_mainview.py (+8/-7)
tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_optionselector.py (+1/-1)
tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_tabbar.py (+1/-1)
tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_tabs.py (+1/-1)
tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_textfield.py (+1/-1)
tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_toolbar.py (+1/-1)
tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/popups.py (+2/-2)
tests/autopilot/ubuntuuitoolkit/tests/__init__.py (+6/-5)
To merge this branch: bzr merge lp:~nskaggs/ubuntu-ui-toolkit/fix-aphelper-emulator-warning
Reviewer Review Type Date Requested Status
PS Jenkins bot continuous-integration Approve
Leo Arias (community) Approve
Tim Peeters Pending
Review via email: mp+227093@code.launchpad.net

This proposal supersedes a proposal from 2014-07-14.

Commit message

Fix the warning for the emulators module. The warning will now only appear if you use the module directly. Bug 134169

Description of the change

Fix the warning for the emulators module by removing it from the base import.

"The ubuntuuitoolkit.emulators module is deprecated. Import the autopilot helpers from the top-level ubuntuuitoolkit module."

The warning will now only appear if you use the module directly.

To post a comment you must log in.
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote : Posted in a previous version of this proposal
review: Approve (continuous-integration)
Revision history for this message
Leo Arias (elopio) wrote : Posted in a previous version of this proposal

The warning is still being printed. Please notice that you need to remove the 'emulators' also from the __all__ list. And emulators is still being used on tests/__init__.py, which is imported by ubuntuuitoolkit. Probably we also need to remove tests from the ubuntuuitoolkit/__init__.py.

Sorry about the mess.

review: Needs Fixing (code review)
Revision history for this message
Tim Peeters (tpeeters) wrote : Posted in a previous version of this proposal

Please submit new MRs for merging into lp:~ubuntu-sdk-team/ubuntu-ui-toolkit/staging. It needs to go there first before we land it in trunk.

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

FAILED: Continuous integration, rev:1060
http://jenkins.qa.ubuntu.com/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-ci/607/
Executed test runs:
    UNSTABLE: http://jenkins.qa.ubuntu.com/job/generic-deb-autopilot-utopic-touch/2102
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-utopic/1760
    SUCCESS: http://jenkins.qa.ubuntu.com/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-utopic-amd64-ci/439
    SUCCESS: http://jenkins.qa.ubuntu.com/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-utopic-armhf-ci/439
        deb: http://jenkins.qa.ubuntu.com/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-utopic-armhf-ci/439/artifact/work/output/*zip*/output.zip
    SUCCESS: http://jenkins.qa.ubuntu.com/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-utopic-i386-ci/439
    UNSTABLE: http://jenkins.qa.ubuntu.com/job/generic-deb-autopilot-runner-mako/2330
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-utopic-armhf/3242
        deb: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-utopic-armhf/3242/artifact/work/output/*zip*/output.zip
    SUCCESS: http://s-jenkins.ubuntu-ci:8080/job/touch-flash-device/9968
    SUCCESS: http://jenkins.qa.ubuntu.com/job/autopilot-testrunner-otto-utopic/1479
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-utopic-amd64/1970
        deb: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-utopic-amd64/1970/artifact/work/output/*zip*/output.zip

Click here to trigger a rebuild:
http://s-jenkins.ubuntu-ci:8080/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-ci/607/rebuild

review: Needs Fixing (continuous-integration)
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 :

FAILED: Continuous integration, rev:1062
http://jenkins.qa.ubuntu.com/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-ci/608/
Executed test runs:
    UNSTABLE: http://jenkins.qa.ubuntu.com/job/generic-deb-autopilot-utopic-touch/2111
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-utopic/1767
    SUCCESS: http://jenkins.qa.ubuntu.com/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-utopic-amd64-ci/440
    SUCCESS: http://jenkins.qa.ubuntu.com/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-utopic-armhf-ci/440
        deb: http://jenkins.qa.ubuntu.com/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-utopic-armhf-ci/440/artifact/work/output/*zip*/output.zip
    SUCCESS: http://jenkins.qa.ubuntu.com/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-utopic-i386-ci/440
    UNSTABLE: http://jenkins.qa.ubuntu.com/job/generic-deb-autopilot-runner-mako/2338
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-utopic-armhf/3256
        deb: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-utopic-armhf/3256/artifact/work/output/*zip*/output.zip
    SUCCESS: http://s-jenkins.ubuntu-ci:8080/job/touch-flash-device/9980
    SUCCESS: http://jenkins.qa.ubuntu.com/job/autopilot-testrunner-otto-utopic/1486
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-utopic-amd64/1979
        deb: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-utopic-amd64/1979/artifact/work/output/*zip*/output.zip

Click here to trigger a rebuild:
http://s-jenkins.ubuntu-ci:8080/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-ci/608/rebuild

review: Needs Fixing (continuous-integration)
Revision history for this message
Nicholas Skaggs (nskaggs) wrote :

Seems we found this bug in autopilot: https://bugs.launchpad.net/ubuntu-calendar-app/+bug/1328600

    self._cached_dt = datetime.fromtimestamp(self[0])
OverflowError: timestamp out of range for platform time_t

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

Triggering rebuild which should be clean now that the bug is solved in staging.

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

FAILED: Continuous integration, rev:1062
http://jenkins.qa.ubuntu.com/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-ci/648/
Executed test runs:
    FAILURE: http://jenkins.qa.ubuntu.com/job/generic-deb-autopilot-utopic-touch/2334/console
    UNSTABLE: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-utopic/1918
    SUCCESS: http://jenkins.qa.ubuntu.com/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-utopic-amd64-ci/480
    SUCCESS: http://jenkins.qa.ubuntu.com/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-utopic-armhf-ci/480
        deb: http://jenkins.qa.ubuntu.com/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-utopic-armhf-ci/480/artifact/work/output/*zip*/output.zip
    SUCCESS: http://jenkins.qa.ubuntu.com/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-utopic-i386-ci/480
    FAILURE: http://jenkins.qa.ubuntu.com/job/generic-deb-autopilot-runner-mako/2518/console
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-utopic-armhf/3545
        deb: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-utopic-armhf/3545/artifact/work/output/*zip*/output.zip
    SUCCESS: http://s-jenkins.ubuntu-ci:8080/job/touch-flash-device/10239
    UNSTABLE: http://jenkins.qa.ubuntu.com/job/autopilot-testrunner-otto-utopic/1608
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-utopic-amd64/2148
        deb: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-utopic-amd64/2148/artifact/work/output/*zip*/output.zip

Click here to trigger a rebuild:
http://s-jenkins.ubuntu-ci:8080/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-ci/648/rebuild

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

PASSED: Continuous integration, rev:1063
http://jenkins.qa.ubuntu.com/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-ci/662/
Executed test runs:
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-deb-autopilot-utopic-touch/2464
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-utopic/1997
    SUCCESS: http://jenkins.qa.ubuntu.com/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-utopic-amd64-ci/494
    SUCCESS: http://jenkins.qa.ubuntu.com/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-utopic-armhf-ci/494
        deb: http://jenkins.qa.ubuntu.com/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-utopic-armhf-ci/494/artifact/work/output/*zip*/output.zip
    SUCCESS: http://jenkins.qa.ubuntu.com/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-utopic-i386-ci/494
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-deb-autopilot-runner-mako/2625
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-utopic-armhf/3707
        deb: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-utopic-armhf/3707/artifact/work/output/*zip*/output.zip
    SUCCESS: http://s-jenkins.ubuntu-ci:8080/job/touch-flash-device/10382
    SUCCESS: http://jenkins.qa.ubuntu.com/job/autopilot-testrunner-otto-utopic/1670
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-utopic-amd64/2247
        deb: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-utopic-amd64/2247/artifact/work/output/*zip*/output.zip

Click here to trigger a rebuild:
http://s-jenkins.ubuntu-ci:8080/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-ci/662/rebuild

review: Approve (continuous-integration)
Revision history for this message
Leo Arias (elopio) wrote :

balloons, your test_import_toolkit_must_not_log_warning is wrong because after patching the log you are not trying to import the module. So the log will always be empty.
I tried to re-import ubuntuuitoolkit, but none of the tricks I have used before worked in this case. Maybe we can get a hand from thomi, barry or mfoord, unless you have a better idea than the ones I tried.

Thanks.

Revision history for this message
Leo Arias (elopio) :
review: Needs Fixing (code review)
Revision history for this message
Nicholas Skaggs (nskaggs) wrote :

Still have to solve ubuntuuitoolkit/tests/test_import.py:28:9: F401 'ubuntuuitoolkit' imported but unused . . .

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

Leo, I think I've fixed your concerns in a quasi sane manner.. I hope at least.

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

FAILED: Continuous integration, rev:1065
http://jenkins.qa.ubuntu.com/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-ci/737/
Executed test runs:
    UNSTABLE: http://jenkins.qa.ubuntu.com/job/generic-deb-autopilot-utopic-touch/3138
    UNSTABLE: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-utopic/2464
    SUCCESS: http://jenkins.qa.ubuntu.com/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-utopic-amd64-ci/569
    SUCCESS: http://jenkins.qa.ubuntu.com/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-utopic-armhf-ci/569
        deb: http://jenkins.qa.ubuntu.com/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-utopic-armhf-ci/569/artifact/work/output/*zip*/output.zip
    SUCCESS: http://jenkins.qa.ubuntu.com/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-utopic-i386-ci/569
    UNSTABLE: http://jenkins.qa.ubuntu.com/job/generic-deb-autopilot-runner-mako/3170
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-utopic-armhf/4382
        deb: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-utopic-armhf/4382/artifact/work/output/*zip*/output.zip
    SUCCESS: http://s-jenkins.ubuntu-ci:8080/job/touch-flash-device/11121
    UNSTABLE: http://jenkins.qa.ubuntu.com/job/autopilot-testrunner-otto-utopic/2041
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-utopic-amd64/2734
        deb: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-utopic-amd64/2734/artifact/work/output/*zip*/output.zip

Click here to trigger a rebuild:
http://s-jenkins.ubuntu-ci:8080/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-ci/737/rebuild

review: Needs Fixing (continuous-integration)
Revision history for this message
Leo Arias (elopio) wrote :

Thanks!

review: Approve
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)
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Needs Fixing (continuous-integration)
Revision history for this message
Nicholas Skaggs (nskaggs) wrote :

hmm

+ make -n coverage-xml
+ grep 'No rule to make target'
make: *** No rule to make target 'coverage-xml'. Stop.

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 :

FAILED: Continuous integration, rev:1066
http://jenkins.qa.ubuntu.com/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-ci/786/
Executed test runs:
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-deb-autopilot-utopic-touch/3382
    FAILURE: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-utopic/2653/console
    SUCCESS: http://jenkins.qa.ubuntu.com/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-utopic-amd64-ci/618
    SUCCESS: http://jenkins.qa.ubuntu.com/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-utopic-armhf-ci/618
        deb: http://jenkins.qa.ubuntu.com/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-utopic-armhf-ci/618/artifact/work/output/*zip*/output.zip
    SUCCESS: http://jenkins.qa.ubuntu.com/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-utopic-i386-ci/618
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-deb-autopilot-runner-mako/3309
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-utopic-armhf/4629
        deb: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-utopic-armhf/4629/artifact/work/output/*zip*/output.zip
    SUCCESS: http://s-jenkins.ubuntu-ci:8080/job/touch-flash-device/11309
    FAILURE: http://jenkins.qa.ubuntu.com/job/autopilot-testrunner-otto-utopic/2145/console
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-utopic-amd64/2930
        deb: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-utopic-amd64/2930/artifact/work/output/*zip*/output.zip

Click here to trigger a rebuild:
http://s-jenkins.ubuntu-ci:8080/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-ci/786/rebuild

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

PASSED: Continuous integration, rev:1066
http://jenkins.qa.ubuntu.com/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-ci/799/
Executed test runs:
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-deb-autopilot-utopic-touch/3446
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-utopic/2708
    SUCCESS: http://jenkins.qa.ubuntu.com/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-utopic-amd64-ci/631
    SUCCESS: http://jenkins.qa.ubuntu.com/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-utopic-armhf-ci/631
        deb: http://jenkins.qa.ubuntu.com/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-utopic-armhf-ci/631/artifact/work/output/*zip*/output.zip
    SUCCESS: http://jenkins.qa.ubuntu.com/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-utopic-i386-ci/631
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-deb-autopilot-runner-mako/3354
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-utopic-armhf/4693
        deb: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-utopic-armhf/4693/artifact/work/output/*zip*/output.zip
    SUCCESS: http://s-jenkins.ubuntu-ci:8080/job/touch-flash-device/11362
    SUCCESS: http://jenkins.qa.ubuntu.com/job/autopilot-testrunner-otto-utopic/2188
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-utopic-amd64/2985
        deb: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-utopic-amd64/2985/artifact/work/output/*zip*/output.zip

Click here to trigger a rebuild:
http://s-jenkins.ubuntu-ci:8080/job/ubuntu-sdk-team-ubuntu-ui-toolkit-staging-ci/799/rebuild

review: Approve (continuous-integration)
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) :
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/ubuntuuitoolkit/__init__.py'
2--- tests/autopilot/ubuntuuitoolkit/__init__.py 2014-07-26 00:10:22 +0000
3+++ tests/autopilot/ubuntuuitoolkit/__init__.py 2014-08-07 18:48:22 +0000
4@@ -23,7 +23,6 @@
5 'check_autopilot_version',
6 'CheckBox',
7 'environment',
8- 'emulators',
9 'fixture_setup',
10 'get_keyboard',
11 'get_pointing_device',
12@@ -50,7 +49,6 @@
13
14 from ubuntuuitoolkit import (
15 base,
16- emulators,
17 environment,
18 fixture_setup,
19 tests,
20
21=== modified file 'tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_checkbox.py'
22--- tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_checkbox.py 2014-04-16 21:13:39 +0000
23+++ tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_checkbox.py 2014-08-07 18:48:22 +0000
24@@ -25,7 +25,7 @@
25
26
27 class CheckBox(_common.UbuntuUIToolkitCustomProxyObjectBase):
28- """CheckBox Autopilot emulator."""
29+ """CheckBox Autopilot custom proxy object."""
30
31 @autopilot_logging.log_action(logger.info)
32 def check(self, timeout=10):
33
34=== modified file 'tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_common.py'
35--- tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_common.py 2014-05-29 16:18:53 +0000
36+++ tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_common.py 2014-08-07 18:48:22 +0000
37@@ -32,7 +32,7 @@
38
39
40 class ToolkitException(Exception):
41- """Exception raised when there is an error with the emulator."""
42+ """Exception raised when there is an error with the custom proxy object."""
43
44
45 def get_pointing_device():
46@@ -59,17 +59,17 @@
47 """Check that the Autopilot installed version matches the one required.
48
49 :raise ToolkitException: If the installed Autopilot version does't
50- match the required by the emulators.
51+ match the required by the custom proxy objects.
52
53 """
54 installed_version = version.LooseVersion(autopilot.version)
55 if installed_version < version.LooseVersion('1.4'):
56 raise ToolkitException(
57- 'The emulators need Autopilot 1.4 or higher.')
58+ 'The custom proxy objects require Autopilot 1.4 or higher.')
59
60
61 class UbuntuUIToolkitCustomProxyObjectBase(dbus.CustomEmulatorBase):
62- """A base class for all the Ubuntu UI Toolkit emulators."""
63+ """A base class for all the Ubuntu UI Toolkit custom proxy objects."""
64
65 def __init__(self, *args):
66 check_autopilot_version()
67
68=== modified file 'tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_header.py'
69--- tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_header.py 2014-07-31 05:40:01 +0000
70+++ tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_header.py 2014-08-07 18:48:22 +0000
71@@ -32,7 +32,7 @@
72
73
74 class AppHeader(_common.UbuntuUIToolkitCustomProxyObjectBase):
75- """AppHeader Autopilot emulator."""
76+ """AppHeader Autopilot custom proxy object."""
77
78 def _show_if_not_visible(self):
79 if not self._is_visible():
80@@ -124,7 +124,7 @@
81 def switch_to_next_tab(self):
82 """Open the next tab.
83
84- :raise ToolkitEmulatorException: If the main view has no tabs.
85+ :raise ToolkitException: If the main view has no tabs.
86
87 """
88 self._show_if_not_visible()
89@@ -154,8 +154,8 @@
90 """Open a tab. This only supports the new tabs in the header
91
92 :parameter index: The index of the tab to open.
93- :raise ToolkitEmulatorException: If the tab index is out of range or
94- useDeprecatedToolbar is set.
95+ :raise ToolkitException: If the tab index is out
96+ of range or useDeprecatedToolbar is set.
97
98 """
99 self._show_if_not_visible()
100
101=== modified file 'tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_mainview.py'
102--- tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_mainview.py 2014-07-29 08:43:51 +0000
103+++ tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_mainview.py 2014-08-07 18:48:22 +0000
104@@ -36,17 +36,17 @@
105
106
107 class MainView(_common.UbuntuUIToolkitCustomProxyObjectBase):
108- """MainView Autopilot emulator."""
109+ """MainView Autopilot custom proxy object."""
110
111 def get_header(self):
112- """Return the AppHeader emulator of the MainView."""
113+ """Return the AppHeader custom proxy object of the MainView."""
114 try:
115 return self.select_single(objectName='MainView_Header')
116 except dbus.StateNotFoundError:
117 raise _common.ToolkitException('The main view has no header.')
118
119 def get_toolbar(self):
120- """Return the Toolbar emulator of the MainView."""
121+ """Return the Toolbar custom proxy object of the MainView."""
122 return self.select_single(_toolbar.Toolbar)
123
124 @autopilot_logging.log_action(logger.info)
125@@ -64,7 +64,7 @@
126 self.get_toolbar().close()
127
128 def get_tabs(self):
129- """Return the Tabs emulator of the MainView.
130+ """Return the Tabs custom proxy object of the MainView.
131
132 :raise ToolkitException: If the main view has no tabs.
133
134@@ -93,7 +93,8 @@
135
136 :parameter index: The index of the tab to open.
137 :return: The newly opened tab.
138- :raise ToolkitEmulatorException: If the tab index is out of range.
139+ :raise ToolkitException: If the tab index
140+ is out of range.
141
142 """
143 if self.useDeprecatedToolbar:
144@@ -114,7 +115,7 @@
145 'Current tab index: {0}.'.format(tabs.selectedTabIndex))
146 if number_of_switches >= number_of_tabs - 1:
147 # This prevents a loop. But if this error is ever raised, it's
148- # likely there's a bug on the emulator or on the QML Tab.
149+ # likely there's a bug on the helper or on the QML Tab.
150 raise _common.ToolkitException(
151 'The tab with index {0} was not selected.'.format(index))
152 current_tab = self.switch_to_next_tab()
153@@ -164,7 +165,7 @@
154 'Tab with objectName "{0}" not found.'.format(object_name))
155
156 def get_action_selection_popover(self, object_name):
157- """Return an ActionSelectionPopover emulator.
158+ """Return an ActionSelectionPopover custom proxy object.
159
160 :parameter object_name: The QML objectName property of the popover.
161
162
163=== modified file 'tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_optionselector.py'
164--- tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_optionselector.py 2014-04-17 01:35:43 +0000
165+++ tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_optionselector.py 2014-08-07 18:48:22 +0000
166@@ -23,7 +23,7 @@
167
168
169 class OptionSelector(_common.UbuntuUIToolkitCustomProxyObjectBase):
170- """OptionSelector Autopilot emulator"""
171+ """OptionSelector Autopilot custom proxy object"""
172
173 def get_option_count(self):
174 """Gets the number of items in the option selector"""
175
176=== modified file 'tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_tabbar.py'
177--- tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_tabbar.py 2014-04-16 21:13:39 +0000
178+++ tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_tabbar.py 2014-08-07 18:48:22 +0000
179@@ -25,7 +25,7 @@
180
181
182 class TabBar(_common.UbuntuUIToolkitCustomProxyObjectBase):
183- """TabBar Autopilot emulator."""
184+ """TabBar Autopilot custom proxy object."""
185
186 @autopilot_logging.log_action(logger.info)
187 def switch_to_next_tab(self):
188
189=== modified file 'tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_tabs.py'
190--- tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_tabs.py 2014-04-16 21:13:39 +0000
191+++ tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_tabs.py 2014-08-07 18:48:22 +0000
192@@ -18,7 +18,7 @@
193
194
195 class Tabs(_common.UbuntuUIToolkitCustomProxyObjectBase):
196- """Tabs Autopilot emulator."""
197+ """Tabs Autopilot custom proxy object."""
198
199 def get_current_tab(self):
200 """Return the currently selected tab."""
201
202=== modified file 'tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_textfield.py'
203--- tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_textfield.py 2014-07-13 07:19:15 +0000
204+++ tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_textfield.py 2014-08-07 18:48:22 +0000
205@@ -23,7 +23,7 @@
206
207
208 class TextField(_common.UbuntuUIToolkitCustomProxyObjectBase):
209- """TextField Autopilot emulator."""
210+ """TextField Autopilot custom proxy object."""
211
212 def __init__(self, *args):
213 super(TextField, self).__init__(*args)
214
215=== modified file 'tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_toolbar.py'
216--- tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_toolbar.py 2014-04-16 21:13:39 +0000
217+++ tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_toolbar.py 2014-08-07 18:48:22 +0000
218@@ -26,7 +26,7 @@
219
220
221 class Toolbar(_common.UbuntuUIToolkitCustomProxyObjectBase):
222- """Toolbar Autopilot emulator."""
223+ """Toolbar Autopilot custom proxy object."""
224
225 @autopilot_logging.log_action(logger.info)
226 def open(self):
227
228=== modified file 'tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/popups.py'
229--- tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/popups.py 2014-07-31 07:18:29 +0000
230+++ tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/popups.py 2014-08-07 18:48:22 +0000
231@@ -66,7 +66,7 @@
232
233
234 class ActionSelectionPopover(_common.UbuntuUIToolkitCustomProxyObjectBase):
235- """ActionSelectionPopover Autopilot emulator."""
236+ """ActionSelectionPopover Autopilot custom proxy object."""
237
238 def click_button_by_text(self, text):
239 """Click a button on the popover.
240@@ -102,7 +102,7 @@
241
242
243 class ComposerSheet(_common.UbuntuUIToolkitCustomProxyObjectBase):
244- """ComposerSheet Autopilot emulator."""
245+ """ComposerSheet Autopilot custom proxy object."""
246
247 def __init__(self, *args):
248 super(ComposerSheet, self).__init__(*args)
249
250=== modified file 'tests/autopilot/ubuntuuitoolkit/tests/__init__.py'
251--- tests/autopilot/ubuntuuitoolkit/tests/__init__.py 2014-07-22 07:44:40 +0000
252+++ tests/autopilot/ubuntuuitoolkit/tests/__init__.py 2014-08-07 18:48:22 +0000
253@@ -23,7 +23,8 @@
254 from autopilot.matchers import Eventually
255 from testtools.matchers import Is, Not, Equals
256
257-from ubuntuuitoolkit import base, emulators, fixture_setup
258+import ubuntuuitoolkit
259+from ubuntuuitoolkit import base, fixture_setup
260
261
262 _DESKTOP_FILE_CONTENTS = ("""[Desktop Entry]
263@@ -91,7 +92,7 @@
264 application_name, _ = os.path.splitext(desktop_file_name)
265 self.app = self.launch_upstart_application(
266 application_name,
267- emulator_base=emulators.UbuntuUIToolkitEmulatorBase)
268+ emulator_base=ubuntuuitoolkit.UbuntuUIToolkitCustomProxyObjectBase)
269
270
271 class QMLStringAppTestCase(UbuntuUIToolkitWithFakeAppRunningTestCase):
272@@ -106,7 +107,7 @@
273
274 @property
275 def main_view(self):
276- return self.app.select_single(emulators.MainView)
277+ return self.app.select_single(ubuntuuitoolkit.MainView)
278
279
280 class FlickDirection:
281@@ -133,7 +134,7 @@
282 "-I" + _get_module_include_path(),
283 self.test_qml_file_path,
284 '--desktop_file_hint={0}'.format(desktop_file_path),
285- emulator_base=emulators.UbuntuUIToolkitEmulatorBase,
286+ emulator_base=ubuntuuitoolkit.UbuntuUIToolkitCustomProxyObjectBase,
287 app_type='qt')
288
289 self.assertThat(
290@@ -149,7 +150,7 @@
291
292 @property
293 def main_view(self):
294- return self.app.select_single(emulators.MainView)
295+ return self.app.select_single(ubuntuuitoolkit.MainView)
296
297 def getOrientationHelper(self):
298 orientationHelper = self.main_view.select_many(

Subscribers

People subscribed via source and target branches