on xenial help sign in
Added indicators-client to AP tests
23ed9deNick Dedekind
CMakeLists.txt+1
@@ -91,6 +91,7 @@ enable_testing()
91# Autopilot tests
91# Autopilot tests
92include(autopilot)
92include(autopilot)
93declare_autopilot_test(unity8 ${CMAKE_SOURCE_DIR}/tests/autopilot/)
93declare_autopilot_test(unity8 ${CMAKE_SOURCE_DIR}/tests/autopilot/)
94+declare_autopilot_test(indicators_client ${CMAKE_SOURCE_DIR}/tests/autopilot/)
94
95
95add_subdirectory(tests)
96add_subdirectory(tests)
96
97
debian/unity8-autopilot.install+1
@@ -1 +1,2 @@
1tests/autopilot/unity8/* usr/lib/python2.7/dist-packages/unity8/
1tests/autopilot/unity8/* usr/lib/python2.7/dist-packages/unity8/
2+tests/autopilot/indicators_client/* usr/lib/python2.7/dist-packages/indicators_client/
tests/autopilot/indicators_client/emulators/main_window.py+1−1
@@ -26,4 +26,4 @@ class MainWindow(object):
26
26
27 def get_power_menu(self):
27 def get_power_menu(self):
28 """Get the power menu from the list"""
28 """Get the power menu from the list"""
29− return self.app.select_single("BasicMenu", objectName="indicator-power");
29+ return self.app.select_single("BasicMenuItem", objectName="indicator-power");
tests/autopilot/indicators_client/tests/test_power.py+2−2
@@ -67,7 +67,7 @@ class TestDisplayMenus(IndicatorsTestCase):
67 def test_auto_bright_switch(self):
67 def test_auto_bright_switch(self):
68 """Test the auto-bright switch"""
68 """Test the auto-bright switch"""
69
69
70− auto_brightness = self.app.select_single("SwitchMenu", objectName="auto-brightness")
70+ auto_brightness = self.app.select_single("SwitchMenuItem", objectName="auto-brightness")
71 self.assertThat(auto_brightness, NotEquals(None))
71 self.assertThat(auto_brightness, NotEquals(None))
72
72
73 old_ab_value = auto_brightness.checked
73 old_ab_value = auto_brightness.checked
@@ -80,7 +80,7 @@ class TestDisplayMenus(IndicatorsTestCase):
80 def test_brightness_slider(self):
80 def test_brightness_slider(self):
81 """Test the auto-bright switch"""
81 """Test the auto-bright switch"""
82
82
83− brightness_menu = self.app.select_single("SliderMenu", objectName="brightness")
83+ brightness_menu = self.app.select_single("SliderMenuItem", objectName="brightness")
84 self.assertThat(brightness_menu, NotEquals(None))
84 self.assertThat(brightness_menu, NotEquals(None))
85
85
86 old_ab_value = brightness_menu.value
86 old_ab_value = brightness_menu.value