Bug 1323169 - Skip tests in test_about_pages.py for Fennec. r=maja_zf
authorHenrik Skupin <mail@hskupin.info>
Tue, 13 Dec 2016 15:15:24 +0100
changeset 325798 9e18bf6548df6c6128717121f08e9056792f4a56
parent 325797 e51e234ad01e0c65b4cdeac6b1f0b401cfb91a73
child 325799 04f20c35dcb7b766fc27cbdbb2e86cc22f8762f9
push id35061
push userhskupin@mozilla.com
push dateWed, 14 Dec 2016 07:24:53 +0000
treeherderautoland@9e18bf6548df [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmaja_zf
bugs1323169
milestone53.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1323169 - Skip tests in test_about_pages.py for Fennec. r=maja_zf MozReview-Commit-ID: ALq4L4V41MJ
testing/marionette/harness/marionette_harness/tests/unit/test_about_pages.py
--- a/testing/marionette/harness/marionette_harness/tests/unit/test_about_pages.py
+++ b/testing/marionette/harness/marionette_harness/tests/unit/test_about_pages.py
@@ -1,16 +1,16 @@
 # This Source Code Form is subject to the terms of the Mozilla Public
 # License, v. 2.0. If a copy of the MPL was not distributed with this
 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
 
 from marionette_driver.by import By
 from marionette_driver.keys import Keys
 
-from marionette_harness import MarionetteTestCase, WindowManagerMixin
+from marionette_harness import MarionetteTestCase, skip_if_mobile, WindowManagerMixin
 
 
 class TestAboutPages(WindowManagerMixin, MarionetteTestCase):
 
     def setUp(self):
         super(TestAboutPages, self).setUp()
 
         if self.marionette.session_capabilities['platformName'] == 'darwin':
@@ -21,16 +21,17 @@ class TestAboutPages(WindowManagerMixin,
         self.remote_uri = self.marionette.absolute_url("javascriptPage.html")
         self.marionette.navigate(self.remote_uri)
 
     def tearDown(self):
         self.close_all_tabs()
 
         super(TestAboutPages, self).tearDown()
 
+    @skip_if_mobile  # Bug 1323185 - Add Fennec support to getWindowHandles
     def test_back_forward(self):
         # Bug 1311041 - Prevent changing of window handle by forcing the test
         # to be run in a new tab.
         new_tab = self.open_tab(trigger='menu')
         self.marionette.switch_to_window(new_tab)
 
         self.marionette.navigate("about:blank")
         self.marionette.navigate(self.remote_uri)
@@ -40,69 +41,74 @@ class TestAboutPages(WindowManagerMixin,
         self.marionette.go_back()
 
         self.wait_for_condition(
             lambda mn: mn.get_url() == self.remote_uri)
 
         self.marionette.close()
         self.marionette.switch_to_window(self.start_tab)
 
+    @skip_if_mobile  # Bug 1323185 - Add Fennec support to getWindowHandles
     def test_navigate_non_remote_about_pages(self):
         # Bug 1311041 - Prevent changing of window handle by forcing the test
         # to be run in a new tab.
         new_tab = self.open_tab(trigger='menu')
         self.marionette.switch_to_window(new_tab)
 
         self.marionette.navigate("about:blank")
         self.assertEqual(self.marionette.get_url(), "about:blank")
         self.marionette.navigate("about:preferences")
         self.assertEqual(self.marionette.get_url(), "about:preferences")
 
         self.marionette.close()
         self.marionette.switch_to_window(self.start_tab)
 
+    @skip_if_mobile  # On Android no shortcuts are available
     def test_navigate_shortcut_key(self):
         def open_with_shortcut():
             with self.marionette.using_context("chrome"):
                 main_win = self.marionette.find_element(By.ID, "main-window")
                 main_win.send_keys(self.mod_key, Keys.SHIFT, 'a')
 
         new_tab = self.open_tab(trigger=open_with_shortcut)
         self.marionette.switch_to_window(new_tab)
 
         self.wait_for_condition(lambda mn: mn.get_url() == "about:addons")
 
         self.marionette.close()
         self.marionette.switch_to_window(self.start_tab)
 
+    @skip_if_mobile  # Bug 1323185 - Add Fennec support to getWindowHandles
     def test_type_to_non_remote_tab(self):
         # Bug 1311041 - Prevent changing of window handle by forcing the test
         # to be run in a new tab.
         new_tab = self.open_tab(trigger='menu')
         self.marionette.switch_to_window(new_tab)
 
         with self.marionette.using_context("chrome"):
             urlbar = self.marionette.find_element(By.ID, 'urlbar')
             urlbar.send_keys(self.mod_key + 'a')
             urlbar.send_keys(self.mod_key + 'x')
             urlbar.send_keys('about:preferences' + Keys.ENTER)
         self.wait_for_condition(lambda mn: mn.get_url() == "about:preferences")
 
         self.marionette.close()
         self.marionette.switch_to_window(self.start_tab)
 
+    @skip_if_mobile  # Interacting with chrome elements not available for Fennec
     def test_type_to_remote_tab(self):
         # about:blank keeps remoteness from remote_uri
         self.marionette.navigate("about:blank")
         with self.marionette.using_context("chrome"):
             urlbar = self.marionette.find_element(By.ID, 'urlbar')
             urlbar.send_keys(self.remote_uri + Keys.ENTER)
 
         self.wait_for_condition(lambda mn: mn.get_url() == self.remote_uri)
 
+    @skip_if_mobile  # Bug 1323185 - Add Fennec support to getWindowHandles
     def test_hang(self):
         # Open a new tab and close the first one
         new_tab = self.open_tab(trigger="menu")
 
         self.marionette.close()
         self.marionette.switch_to_window(new_tab)
 
         self.marionette.navigate(self.remote_uri)