← Back to team overview

ubuntu-touch-coreapps-reviewers team mailing list archive

[Merge] lp:~ahayzen/ubuntu-weather-app/fix-1485657-flaky-test into lp:ubuntu-weather-app/reboot

 

Andrew Hayzen has proposed merging lp:~ahayzen/ubuntu-weather-app/fix-1485657-flaky-test into lp:ubuntu-weather-app/reboot.

Commit message:
* Fix for flaky test as get_location does not wait for location to be loaded

Requested reviews:
  Ubuntu Weather Developers (ubuntu-weather-dev)
Related bugs:
  Bug #1485657 in Ubuntu Weather App: "TestAddLocationPage.test_add_location_via_search sometimes fails"
  https://bugs.launchpad.net/ubuntu-weather-app/+bug/1485657

For more details, see:
https://code.launchpad.net/~ahayzen/ubuntu-weather-app/fix-1485657-flaky-test/+merge/268250

* Fix for flaky test as get_location does not wait for location to be loaded

This fixes a flaky test that was found while testing other AP branches, basically the location can take a while to appear on slower connections in the list so that select_single should be a wait_select_single.
-- 
Your team Ubuntu Weather Developers is requested to review the proposed merge of lp:~ahayzen/ubuntu-weather-app/fix-1485657-flaky-test into lp:ubuntu-weather-app/reboot.
=== modified file 'debian/changelog'
--- debian/changelog	2015-08-14 00:11:12 +0000
+++ debian/changelog	2015-08-17 15:56:34 +0000
@@ -32,6 +32,7 @@
   * Create autopilot test which adds a location via searching (LP: #1452497)
   * Create autopilot test which adds a location via cached results (LP: #1452497)
   * Fix for racy search bar causing incorrect search query when typed quickly
+  * Fix for flaky test as get_location does not wait for location to be loaded (LP: #1485657)
 
   [ Carla Sella ]
   * Create autopilot test which shows the day delegate (LP: #1452491) 

=== modified file 'po/com.ubuntu.weather.pot'
--- po/com.ubuntu.weather.pot	2015-08-07 00:16:54 +0000
+++ po/com.ubuntu.weather.pot	2015-08-17 15:56:34 +0000
@@ -8,7 +8,7 @@
 msgstr ""
 "Project-Id-Version: ubuntu-weather-app\n"
 "Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2015-08-06 19:16-0500\n"
+"POT-Creation-Date: 2015-08-12 00:11+0100\n"
 "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
 "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
 "Language-Team: LANGUAGE <LL@xxxxxx>\n"
@@ -18,31 +18,31 @@
 "Content-Transfer-Encoding: 8bit\n"
 "Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n"
 
-#: ../app/components/DayDelegate.qml:199
+#: ../app/components/DayDelegate.qml:200
 msgid "Chance of rain"
 msgstr ""
 
-#: ../app/components/DayDelegate.qml:205
+#: ../app/components/DayDelegate.qml:206
 msgid "Winds"
 msgstr ""
 
-#: ../app/components/DayDelegate.qml:212
+#: ../app/components/DayDelegate.qml:213
 msgid "UV Index"
 msgstr ""
 
-#: ../app/components/DayDelegate.qml:217
+#: ../app/components/DayDelegate.qml:218
 msgid "Pollen"
 msgstr ""
 
-#: ../app/components/DayDelegate.qml:223
+#: ../app/components/DayDelegate.qml:224
 msgid "Humidity"
 msgstr ""
 
-#: ../app/components/DayDelegate.qml:229
+#: ../app/components/DayDelegate.qml:230
 msgid "Sunrise"
 msgstr ""
 
-#: ../app/components/DayDelegate.qml:235
+#: ../app/components/DayDelegate.qml:236
 msgid "Sunset"
 msgstr ""
 

=== modified file 'tests/autopilot/ubuntu_weather_app/__init__.py'
--- tests/autopilot/ubuntu_weather_app/__init__.py	2015-08-14 00:11:12 +0000
+++ tests/autopilot/ubuntu_weather_app/__init__.py	2015-08-17 15:56:34 +0000
@@ -155,8 +155,8 @@
         self.main_view.get_header().click_action_button("addLocation")
 
     def get_location(self, index):
-        return self.select_single(WeatherListItem,
-                                  objectName="location" + str(index))
+        return self.wait_select_single(WeatherListItem,
+                                       objectName="location" + str(index))
 
 
 class MainView(MainView):


Follow ups