Merge lp:~canonical-platform-qa/ubuntu-system-tests/use_uitk_base into lp:ubuntu-system-tests

Proposed by Brendan Donegan
Status: Merged
Approved by: Sergio Cazzolato
Approved revision: 116
Merged at revision: 117
Proposed branch: lp:~canonical-platform-qa/ubuntu-system-tests/use_uitk_base
Merge into: lp:ubuntu-system-tests
Diff against target: 116 lines (+11/-16)
5 files modified
ubuntu_system_tests/helpers/camera.py (+1/-1)
ubuntu_system_tests/tests/base.py (+1/-2)
ubuntu_system_tests/tests/test_add_contact.py (+2/-1)
ubuntu_system_tests/tests/test_sim_pin.py (+3/-2)
ubuntu_system_tests/tests/test_with_webbrowser.py (+4/-10)
To merge this branch: bzr merge lp:~canonical-platform-qa/ubuntu-system-tests/use_uitk_base
Reviewer Review Type Date Requested Status
PS Jenkins bot continuous-integration Approve
Sergio Cazzolato Approve
Review via email: mp+259824@code.launchpad.net

Commit message

Take into account changes in Autopilot to fix CPO handling

Description of the change

Tests need to take into account changes in Autopilot to fix CPO handling

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)
Revision history for this message
Sergio Cazzolato (sergio-j-cazzolato) :
review: Approve
116. By Brendan Donegan

Fix flake8 issues

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

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'ubuntu_system_tests/helpers/camera.py'
2--- ubuntu_system_tests/helpers/camera.py 2015-05-21 18:15:40 +0000
3+++ ubuntu_system_tests/helpers/camera.py 2015-06-02 16:02:42 +0000
4@@ -97,7 +97,7 @@
5 self.get_option_value_button(value))
6
7
8-class Panel(uitk.UbuntuUIToolkitCustomProxyObjectBase, Panel):
9+class Panel(Panel):
10 """Class to over-ride default Panel helper."""
11
12 @autopilot.logging.log_action(logger.info)
13
14=== modified file 'ubuntu_system_tests/tests/base.py'
15--- ubuntu_system_tests/tests/base.py 2015-05-21 18:15:40 +0000
16+++ ubuntu_system_tests/tests/base.py 2015-06-02 16:02:42 +0000
17@@ -32,7 +32,6 @@
18 from unity8.shell.emulators import dash
19
20 from ubuntu_system_tests.helpers import unity8
21-from ubuntu_system_tests.helpers.unity8 import shell
22
23
24 logger = logging.getLogger(__name__)
25@@ -63,7 +62,7 @@
26 pid = process_helpers.get_job_pid('unity8')
27 unity = introspection.get_proxy_object_for_existing_process(
28 pid=pid,
29- emulator_base=shell.Unity8
30+ emulator_base=ubuntuuitoolkit.UbuntuUIToolkitCustomProxyObjectBase
31 )
32 unity.wait_for_greeter_content()
33 return unity
34
35=== modified file 'ubuntu_system_tests/tests/test_add_contact.py'
36--- ubuntu_system_tests/tests/test_add_contact.py 2015-05-21 18:15:40 +0000
37+++ ubuntu_system_tests/tests/test_add_contact.py 2015-06-02 16:02:42 +0000
38@@ -21,6 +21,7 @@
39 import subprocess
40
41 import address_book_app
42+import ubuntuuitoolkit
43
44 from ubuntu_system_tests.tests import base
45 from ubuntu_system_tests.helpers import autopilot as autopilot_helpers
46@@ -54,7 +55,7 @@
47 apps_scope.click_scope_item('predefined', 'Contacts')
48 return autopilot_helpers.get_proxy_object_for_existing_process(
49 'address-book-app',
50- address_book_app.AddressBookApp)
51+ ubuntuuitoolkit.UbuntuUIToolkitCustomProxyObjectBase)
52
53 def test_add_contact_with_name_and_number(self):
54 test_contact = self.get_test_contact()
55
56=== modified file 'ubuntu_system_tests/tests/test_sim_pin.py'
57--- ubuntu_system_tests/tests/test_sim_pin.py 2015-05-21 18:15:40 +0000
58+++ ubuntu_system_tests/tests/test_sim_pin.py 2015-06-02 16:02:42 +0000
59@@ -19,7 +19,7 @@
60 #
61
62 import autopilot
63-import ubuntu_system_settings
64+import ubuntuuitoolkit
65 from autopilot import exceptions
66 from autopilot.matchers import Eventually
67 from testtools.matchers import Equals
68@@ -62,7 +62,8 @@
69 self.addCleanup(ensure_system_settings_closed)
70
71 self.app = autopilot_helpers.get_proxy_object_for_existing_process(
72- 'system-settings', ubuntu_system_settings.SystemSettings)
73+ 'system-settings',
74+ ubuntuuitoolkit.UbuntuUIToolkitCustomProxyObjectBase)
75 # As per this bug where we're unable to launch the browser from the
76 # scope after a unity8 reboot.
77 # https://bugs.launchpad.net/ubuntu/+source/unity8/+bug/1401361
78
79=== modified file 'ubuntu_system_tests/tests/test_with_webbrowser.py'
80--- ubuntu_system_tests/tests/test_with_webbrowser.py 2015-05-21 18:15:40 +0000
81+++ ubuntu_system_tests/tests/test_with_webbrowser.py 2015-06-02 16:02:42 +0000
82@@ -42,7 +42,8 @@
83 import shutil
84 import subprocess
85
86-from autopilot import exceptions, platform
87+import ubuntuuitoolkit
88+from autopilot import exceptions
89 from collections import namedtuple
90
91 from ubuntu_system_tests.helpers import autopilot as autopilot_helpers
92@@ -53,14 +54,6 @@
93
94 # Testing vivid on the device but the host doesn't need to be vivid (or have
95 # the up-to-date helpers.)
96-try:
97- from webbrowser_app.emulators.browser import Webbrowser
98-except ImportError:
99- if platform.model() == 'Desktop':
100- logger.info('Ignoring webrowser import error due to running on host.')
101- else:
102- raise
103-
104
105 PageUrls = namedtuple('PageUrls', ['entered_url', 'title_url', 'actual_url'])
106 logger = logging.getLogger(__name__)
107@@ -122,7 +115,8 @@
108 )
109
110 browser = autopilot_helpers.get_proxy_object_for_existing_process(
111- 'webbrowser-app', Webbrowser)
112+ 'webbrowser-app',
113+ ubuntuuitoolkit.UbuntuUIToolkitCustomProxyObjectBase)
114
115 # As per this bug where we're unable to launch the browser from the
116 # scope after a unity8 reboot.

Subscribers

People subscribed via source and target branches

to all changes: