Merge ~kissiel/checkbox-converged:autopilot-fixes into checkbox-converged:master

Proposed by Maciej Kisielewski
Status: Merged
Approved by: Maciej Kisielewski
Approved revision: 2d08563731ec6f20c88628b63d751aac3ff64376
Merged at revision: 74628d84be1be83d518a533e382f5a846c5cab9e
Proposed branch: ~kissiel/checkbox-converged:autopilot-fixes
Merge into: checkbox-converged:master
Diff against target: 59 lines (+7/-5)
3 files modified
get-libs (+2/-2)
tests/autopilot/checkbox_converged/__init__.py (+1/-0)
utils.py (+4/-3)
Reviewer Review Type Date Requested Status
Sylvain Pineau (community) Approve
Review via email: mp+332649@code.launchpad.net

Description of the change

fix autopilot failures

The following two patches fix ./get-libs crashes
9b8ff32 copy trusted.gpg only if exists
39e6eb0 bump repo used to xenial

This one fixes deployment/packaging of the app.
27a776e use new pkg name for pyotherside

This one fixes autopilot on systems that have some global providers installed
(scenarios were broken, as they were too many test plans visible on the screen, and AP couldn't find the correct one)
2d08563 ignore installed providers when running autopilot

To post a comment you must log in.
Revision history for this message
Sylvain Pineau (sylvain-pineau) wrote :

looks good to me, +1

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
diff --git a/get-libs b/get-libs
index 4b3e2c9..d310b66 100755
--- a/get-libs
+++ b/get-libs
@@ -113,7 +113,7 @@ def main():
113 # skip downloading rest of the libs113 # skip downloading rest of the libs
114 return114 return
115 packages = [115 packages = [
116 'libpython3.5', 'pyotherside', 'python3-xlsxwriter',116 'libpython3.5', 'qml-module-io-thp-pyotherside', 'python3-xlsxwriter',
117 'python3-jinja2', 'python3-markupsafe', 'python3-padme',117 'python3-jinja2', 'python3-markupsafe', 'python3-padme',
118 'python3-requests', 'python3-urllib3', 'python3-guacamole',118 'python3-requests', 'python3-urllib3', 'python3-guacamole',
119 'python3-requests-oauthlib']119 'python3-requests-oauthlib']
@@ -161,7 +161,7 @@ def main():
161 os.path.join('lib', 'py'),161 os.path.join('lib', 'py'),
162 preserve_symlinks=1)162 preserve_symlinks=1)
163 with tempfile.TemporaryDirectory() as tmp:163 with tempfile.TemporaryDirectory() as tmp:
164 get_package_from_url_and_extract(uris['pyotherside'], tmp)164 get_package_from_url_and_extract(uris['qml-module-io-thp-pyotherside'], tmp)
165 src = os.path.join(165 src = os.path.join(
166 tmp, 'usr', 'lib', 'arm-linux-gnueabihf', 'qt5', 'qml')166 tmp, 'usr', 'lib', 'arm-linux-gnueabihf', 'qt5', 'qml')
167 dest = os.path.join('lib', 'arm-linux-gnueabihf')167 dest = os.path.join('lib', 'arm-linux-gnueabihf')
diff --git a/tests/autopilot/checkbox_converged/__init__.py b/tests/autopilot/checkbox_converged/__init__.py
index c4d2027..21f62fc 100644
--- a/tests/autopilot/checkbox_converged/__init__.py
+++ b/tests/autopilot/checkbox_converged/__init__.py
@@ -183,6 +183,7 @@ class ClickAppTestCase(base.UbuntuUIToolkitAppTestCase):
183 def _launch_application_from_desktop(self):183 def _launch_application_from_desktop(self):
184 app_qml_source_location = self._get_app_qml_source_path()184 app_qml_source_location = self._get_app_qml_source_path()
185 if os.path.exists(app_qml_source_location):185 if os.path.exists(app_qml_source_location):
186 os.environ['PROVIDERPATH'] = ''
186 self.app = self.launch_test_application(187 self.app = self.launch_test_application(
187 base.get_qmlscene_launch_command(),188 base.get_qmlscene_launch_command(),
188 '-I', self._get_plainbox_qml_modules_path(),189 '-I', self._get_plainbox_qml_modules_path(),
diff --git a/utils.py b/utils.py
index 1fd65b5..149a254 100644
--- a/utils.py
+++ b/utils.py
@@ -57,8 +57,9 @@ def prepare_uris(packages):
57 new_etc_apt = os.path.join(tmp, 'etc', 'apt')57 new_etc_apt = os.path.join(tmp, 'etc', 'apt')
58 os.makedirs(new_etc_apt)58 os.makedirs(new_etc_apt)
59 # copy over trusted.gpg59 # copy over trusted.gpg
60 shutil.copyfile('/etc/apt/trusted.gpg',60 if os.path.exists('/etc/apt/trusted.gpg'):
61 os.path.join(new_etc_apt, 'trusted.gpg'))61 shutil.copyfile('/etc/apt/trusted.gpg',
62 os.path.join(new_etc_apt, 'trusted.gpg'))
62 # copy over additional keyrings63 # copy over additional keyrings
63 if os.path.exists('/etc/apt/trusted.gpg.d'):64 if os.path.exists('/etc/apt/trusted.gpg.d'):
64 shutil.copytree('/etc/apt/trusted.gpg.d',65 shutil.copytree('/etc/apt/trusted.gpg.d',
@@ -66,7 +67,7 @@ def prepare_uris(packages):
66 sources_list = open(os.path.join(new_etc_apt, 'sources.list'), "w")67 sources_list = open(os.path.join(new_etc_apt, 'sources.list'), "w")
67 for source in sources:68 for source in sources:
68 sources_list.write(69 sources_list.write(
69 "deb [arch=armhf] {uri} wily {repositories}\n".format(70 "deb [arch=armhf] {uri} xenial {repositories}\n".format(
70 uri=source.uri, repositories=source.repositories))71 uri=source.uri, repositories=source.repositories))
71 sources_list.close()72 sources_list.close()
72 apt_pkg.config["Apt::Architecture"] = 'armhf'73 apt_pkg.config["Apt::Architecture"] = 'armhf'

Subscribers

People subscribed via source and target branches