From a502827c68e10e3fceb1cece8eb62e7b81bcc6d5 Mon Sep 17 00:00:00 2001 From: Ryan VanderMeulen Date: Wed, 11 Feb 2015 12:15:22 -0500 Subject: [PATCH] Backed out 12 changesets (bug 1107336) for Marionette harness bustage on a CLOSED TREE. Backed out changeset 5075f0063d70 (bug 1107336) Backed out changeset 9ef91d4fcf3b (bug 1107336) Backed out changeset 995911340bf7 (bug 1107336) Backed out changeset 4817d3cd3810 (bug 1107336) Backed out changeset dad798a5e595 (bug 1107336) Backed out changeset 4f60c437140c (bug 1107336) Backed out changeset f92a5c6256fa (bug 1107336) Backed out changeset 399a436c6e5f (bug 1107336) Backed out changeset 0d04801bb2f0 (bug 1107336) Backed out changeset 60d9d4d20971 (bug 1107336) Backed out changeset 9c4b171c23be (bug 1107336) Backed out changeset a07bb95eb209 (bug 1107336) --HG-- rename : testing/marionette/driver/marionette_driver/application_cache.py => testing/marionette/client/marionette/application_cache.py rename : testing/marionette/driver/marionette_driver/by.py => testing/marionette/client/marionette/by.py rename : testing/marionette/driver/marionette_driver/date_time_value.py => testing/marionette/client/marionette/date_time_value.py rename : testing/marionette/driver/marionette_driver/decorators.py => testing/marionette/client/marionette/decorators.py rename : testing/marionette/driver/marionette_driver/errors.py => testing/marionette/client/marionette/errors.py rename : testing/marionette/driver/marionette_driver/expected.py => testing/marionette/client/marionette/expected.py rename : testing/marionette/driver/marionette_driver/geckoinstance.py => testing/marionette/client/marionette/geckoinstance.py rename : testing/marionette/driver/marionette_driver/gestures.py => testing/marionette/client/marionette/gestures.py rename : testing/marionette/driver/marionette_driver/keys.py => testing/marionette/client/marionette/keys.py rename : testing/marionette/driver/marionette_driver/marionette.py => testing/marionette/client/marionette/marionette.py rename : testing/marionette/driver/marionette_driver/selection.py => testing/marionette/client/marionette/selection.py rename : testing/marionette/driver/marionette_driver/wait.py => testing/marionette/client/marionette/wait.py --- .../test/functional/test_1_browser_call.py | 16 ++++------ .../loop/test/shared/frontend_tester.py | 2 +- build/mach_bootstrap.py | 1 - build/virtualenv_packages.txt | 1 - .../tests/marionette/test_selectioncarets.py | 8 ++--- .../test_selectioncarets_multiplerange.py | 8 ++--- .../base/tests/marionette/test_touchcaret.py | 6 ++-- layout/tools/reftest/b2g_desktop.py | 8 ++--- testing/config/marionette_requirements.txt | 1 - .../marionette/client/marionette/__init__.py | 29 +++++++++++++++++++ .../marionette}/application_cache.py | 0 .../client/marionette/b2g_update_test.py | 4 +-- .../marionette}/by.py | 0 .../marionette}/date_time_value.py | 0 .../marionette}/decorators.py | 0 .../marionette}/errors.py | 0 .../marionette}/expected.py | 0 .../marionette}/geckoinstance.py | 0 .../marionette}/gestures.py | 0 .../marionette}/keys.py | 0 .../marionette}/marionette.py | 0 .../client/marionette/marionette_test.py | 9 +++--- .../client/marionette/runner/base.py | 2 +- .../marionette}/selection.py | 0 .../tests/unit/single_finger_functions.py | 4 +-- .../tests/unit/test_accessibility.py | 4 +-- .../tests/unit/test_anonymous_content.py | 9 +++--- .../marionette/tests/unit/test_appcache.py | 4 +-- .../tests/unit/test_capabilities.py | 2 +- .../marionette/tests/unit/test_clearing.py | 4 +-- .../marionette/tests/unit/test_click.py | 6 ++-- .../tests/unit/test_click_chrome.py | 2 +- .../tests/unit/test_click_scrolling.py | 4 +-- .../tests/unit/test_date_time_value.py | 2 +- .../tests/unit/test_element_touch.py | 2 +- .../marionette/tests/unit/test_emulator.py | 3 +- .../marionette/tests/unit/test_errors.py | 5 ++-- .../tests/unit/test_execute_async_script.py | 4 +-- .../tests/unit/test_execute_isolate.py | 4 +-- .../tests/unit/test_execute_script.py | 4 +-- .../marionette/tests/unit/test_expected.py | 5 ++-- .../marionette/tests/unit/test_findelement.py | 6 ++-- .../tests/unit/test_findelement_chrome.py | 6 ++-- .../tests/unit/test_implicit_waits.py | 2 +- .../tests/unit/test_import_script.py | 12 ++++---- .../marionette/tests/unit/test_marionette.py | 2 +- .../marionette/tests/unit/test_navigation.py | 2 +- .../tests/unit/test_profile_management.py | 2 +- .../tests/unit/test_screen_orientation.py | 2 +- .../tests/unit/test_set_window_size.py | 2 +- .../tests/unit/test_simpletest_sanity.py | 4 +-- .../tests/unit/test_single_finger.py | 4 +-- .../tests/unit/test_single_finger_desktop.py | 4 +-- .../tests/unit/test_specialpowers.py | 4 +-- .../marionette/tests/unit/test_submit.py | 7 +++-- .../tests/unit/test_switch_frame.py | 4 +-- .../tests/unit/test_switch_frame_chrome.py | 10 +++++-- .../client/marionette/tests/unit/test_text.py | 2 +- .../marionette/tests/unit/test_timeouts.py | 7 ++--- .../marionette/tests/unit/test_typing.py | 4 +-- .../client/marionette/tests/unit/test_wait.py | 7 ++--- .../tests/unit/test_window_handles.py | 4 +-- .../tests/unit/test_window_position.py | 2 +- .../tests/unit/test_window_switching.py | 7 ++--- .../tests/unit/test_with_using_context.py | 2 +- .../marionette}/wait.py | 0 testing/marionette/client/requirements.txt | 1 - .../driver/marionette_driver/__init__.py | 8 ----- testing/marionette/driver/requirements.txt | 1 - testing/marionette/driver/setup.py | 27 ----------------- testing/testsuite-targets.mk | 2 -- 71 files changed, 140 insertions(+), 170 deletions(-) rename testing/marionette/{driver/marionette_driver => client/marionette}/application_cache.py (100%) rename testing/marionette/{driver/marionette_driver => client/marionette}/by.py (100%) rename testing/marionette/{driver/marionette_driver => client/marionette}/date_time_value.py (100%) rename testing/marionette/{driver/marionette_driver => client/marionette}/decorators.py (100%) rename testing/marionette/{driver/marionette_driver => client/marionette}/errors.py (100%) rename testing/marionette/{driver/marionette_driver => client/marionette}/expected.py (100%) rename testing/marionette/{driver/marionette_driver => client/marionette}/geckoinstance.py (100%) rename testing/marionette/{driver/marionette_driver => client/marionette}/gestures.py (100%) rename testing/marionette/{driver/marionette_driver => client/marionette}/keys.py (100%) rename testing/marionette/{driver/marionette_driver => client/marionette}/marionette.py (100%) rename testing/marionette/{driver/marionette_driver => client/marionette}/selection.py (100%) rename testing/marionette/{driver/marionette_driver => client/marionette}/wait.py (100%) delete mode 100644 testing/marionette/driver/marionette_driver/__init__.py delete mode 100644 testing/marionette/driver/requirements.txt delete mode 100644 testing/marionette/driver/setup.py diff --git a/browser/components/loop/test/functional/test_1_browser_call.py b/browser/components/loop/test/functional/test_1_browser_call.py index 54281267178..70c17b7456d 100644 --- a/browser/components/loop/test/functional/test_1_browser_call.py +++ b/browser/components/loop/test/functional/test_1_browser_call.py @@ -1,18 +1,12 @@ from marionette_test import MarionetteTestCase -try: - from by import By - from errors import NoSuchElementException, StaleElementException - # noinspection PyUnresolvedReferences - from wait import Wait -except ImportError: - from marionette_driver.by import By - from marionette_driver.errors import NoSuchElementException, StaleElementException - # noinspection PyUnresolvedReferences - from marionette_driver import Wait +from by import By +import urlparse +from errors import NoSuchElementException, StaleElementException +# noinspection PyUnresolvedReferences +from wait import Wait import os import sys -import urlparse sys.path.insert(1, os.path.dirname(os.path.abspath(__file__))) import pyperclip diff --git a/browser/components/loop/test/shared/frontend_tester.py b/browser/components/loop/test/shared/frontend_tester.py index d5364853a17..7835fae0b9d 100644 --- a/browser/components/loop/test/shared/frontend_tester.py +++ b/browser/components/loop/test/shared/frontend_tester.py @@ -1,5 +1,5 @@ from marionette_test import MarionetteTestCase -from marionette_driver.errors import NoSuchElementException +from errors import NoSuchElementException import threading import SimpleHTTPServer import SocketServer diff --git a/build/mach_bootstrap.py b/build/mach_bootstrap.py index 87d3c06d2ab..f839b03502e 100644 --- a/build/mach_bootstrap.py +++ b/build/mach_bootstrap.py @@ -51,7 +51,6 @@ SEARCH_PATHS = [ 'testing/marionette/client', 'testing/marionette/client/marionette', 'testing/marionette/transport', - 'testing/marionette/driver', 'testing/mozbase/mozcrash', 'testing/mozbase/mozdebug', 'testing/mozbase/mozdevice', diff --git a/build/virtualenv_packages.txt b/build/virtualenv_packages.txt index 1dace34d23f..c442dc5ea24 100644 --- a/build/virtualenv_packages.txt +++ b/build/virtualenv_packages.txt @@ -1,5 +1,4 @@ marionette_transport.pth:testing/marionette/transport -marionette_driver.pth:testing/marionette/driver marionette.pth:testing/marionette/client blessings.pth:python/blessings configobj.pth:python/configobj diff --git a/layout/base/tests/marionette/test_selectioncarets.py b/layout/base/tests/marionette/test_selectioncarets.py index a40b3c17022..bf283e5f02b 100644 --- a/layout/base/tests/marionette/test_selectioncarets.py +++ b/layout/base/tests/marionette/test_selectioncarets.py @@ -3,11 +3,11 @@ # 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.marionette import Actions +from by import By +from marionette import Actions from marionette_test import MarionetteTestCase -from marionette_driver.selection import SelectionManager -from marionette_driver.gestures import long_press_without_contextmenu +from selection import SelectionManager +from gestures import long_press_without_contextmenu class SelectionCaretsTest(MarionetteTestCase): diff --git a/layout/base/tests/marionette/test_selectioncarets_multiplerange.py b/layout/base/tests/marionette/test_selectioncarets_multiplerange.py index 9cfbe465268..cc164865441 100644 --- a/layout/base/tests/marionette/test_selectioncarets_multiplerange.py +++ b/layout/base/tests/marionette/test_selectioncarets_multiplerange.py @@ -3,11 +3,11 @@ # 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.marionette import Actions +from by import By +from marionette import Actions from marionette_test import MarionetteTestCase -from marionette_driver.selection import SelectionManager -from marionette_driver.gestures import long_press_without_contextmenu +from selection import SelectionManager +from gestures import long_press_without_contextmenu class SelectionCaretsMultipleRangeTest(MarionetteTestCase): diff --git a/layout/base/tests/marionette/test_touchcaret.py b/layout/base/tests/marionette/test_touchcaret.py index 61a37760936..9ef93af1b43 100644 --- a/layout/base/tests/marionette/test_touchcaret.py +++ b/layout/base/tests/marionette/test_touchcaret.py @@ -3,10 +3,10 @@ # 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.marionette import Actions -from marionette_driver.selection import SelectionManager +from by import By +from marionette import Actions from marionette_test import MarionetteTestCase +from selection import SelectionManager class TouchCaretTest(MarionetteTestCase): diff --git a/layout/tools/reftest/b2g_desktop.py b/layout/tools/reftest/b2g_desktop.py index b4a0b414c12..15debfe5fba 100644 --- a/layout/tools/reftest/b2g_desktop.py +++ b/layout/tools/reftest/b2g_desktop.py @@ -11,11 +11,9 @@ here = os.path.abspath(os.path.dirname(__file__)) from runreftest import RefTest, ReftestOptions -from marionette_driver import expected -from marionette_driver.by import By -from marionette_driver.marionette import Marionette -from marionette_driver.wait import Wait - +from marionette import Marionette, expected +from marionette.wait import Wait +from marionette.by import By from mozprocess import ProcessHandler from mozrunner import FirefoxRunner import mozinfo diff --git a/testing/config/marionette_requirements.txt b/testing/config/marionette_requirements.txt index ab683343728..186360841e5 100644 --- a/testing/config/marionette_requirements.txt +++ b/testing/config/marionette_requirements.txt @@ -1,4 +1,3 @@ -r mozbase_requirements.txt ../marionette/transport -../marionette/driver ../marionette diff --git a/testing/marionette/client/marionette/__init__.py b/testing/marionette/client/marionette/__init__.py index 78b88f62dcc..67a263367d5 100644 --- a/testing/marionette/client/marionette/__init__.py +++ b/testing/marionette/client/marionette/__init__.py @@ -2,7 +2,33 @@ # 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 gestures import smooth_scroll, pinch +from by import By +from marionette import Marionette, HTMLElement, Actions, MultiActions from marionette_test import MarionetteTestCase, MarionetteJSTestCase, CommonTestCase, expectedFailure, skip, SkipTest +from errors import ( + ElementNotVisibleException, + ElementNotAccessibleException, + ErrorCodes, + FrameSendFailureError, + FrameSendNotInitializedError, + InvalidCookieDomainException, + InvalidElementStateException, + InvalidResponseException, + InvalidSelectorException, + JavascriptException, + MarionetteException, + MoveTargetOutOfBoundsException, + NoAlertPresentException, + NoSuchElementException, + NoSuchFrameException, + NoSuchWindowException, + ScriptTimeoutException, + StaleElementException, + TimeoutException, + UnableToSetCookieException, + XPathLookupException, +) from runner import ( B2GTestCaseMixin, B2GTestResultMixin, @@ -24,3 +50,6 @@ from runner import ( TestResult, TestResultCollection ) +from wait import Wait +from date_time_value import DateTimeValue +import decorators diff --git a/testing/marionette/driver/marionette_driver/application_cache.py b/testing/marionette/client/marionette/application_cache.py similarity index 100% rename from testing/marionette/driver/marionette_driver/application_cache.py rename to testing/marionette/client/marionette/application_cache.py diff --git a/testing/marionette/client/marionette/b2g_update_test.py b/testing/marionette/client/marionette/b2g_update_test.py index 5c832922e46..ea1c4d2b04e 100644 --- a/testing/marionette/client/marionette/b2g_update_test.py +++ b/testing/marionette/client/marionette/b2g_update_test.py @@ -12,8 +12,8 @@ import types import weakref from b2ginstance import B2GInstance -from marionette_driver.errors import InvalidResponseException -from marionette_driver.marionette import Marionette +from errors import InvalidResponseException +from marionette import Marionette from marionette_test import MarionetteTestCase from marionette_transport import MarionetteTransport from runtests import MarionetteTestRunner, cli diff --git a/testing/marionette/driver/marionette_driver/by.py b/testing/marionette/client/marionette/by.py similarity index 100% rename from testing/marionette/driver/marionette_driver/by.py rename to testing/marionette/client/marionette/by.py diff --git a/testing/marionette/driver/marionette_driver/date_time_value.py b/testing/marionette/client/marionette/date_time_value.py similarity index 100% rename from testing/marionette/driver/marionette_driver/date_time_value.py rename to testing/marionette/client/marionette/date_time_value.py diff --git a/testing/marionette/driver/marionette_driver/decorators.py b/testing/marionette/client/marionette/decorators.py similarity index 100% rename from testing/marionette/driver/marionette_driver/decorators.py rename to testing/marionette/client/marionette/decorators.py diff --git a/testing/marionette/driver/marionette_driver/errors.py b/testing/marionette/client/marionette/errors.py similarity index 100% rename from testing/marionette/driver/marionette_driver/errors.py rename to testing/marionette/client/marionette/errors.py diff --git a/testing/marionette/driver/marionette_driver/expected.py b/testing/marionette/client/marionette/expected.py similarity index 100% rename from testing/marionette/driver/marionette_driver/expected.py rename to testing/marionette/client/marionette/expected.py diff --git a/testing/marionette/driver/marionette_driver/geckoinstance.py b/testing/marionette/client/marionette/geckoinstance.py similarity index 100% rename from testing/marionette/driver/marionette_driver/geckoinstance.py rename to testing/marionette/client/marionette/geckoinstance.py diff --git a/testing/marionette/driver/marionette_driver/gestures.py b/testing/marionette/client/marionette/gestures.py similarity index 100% rename from testing/marionette/driver/marionette_driver/gestures.py rename to testing/marionette/client/marionette/gestures.py diff --git a/testing/marionette/driver/marionette_driver/keys.py b/testing/marionette/client/marionette/keys.py similarity index 100% rename from testing/marionette/driver/marionette_driver/keys.py rename to testing/marionette/client/marionette/keys.py diff --git a/testing/marionette/driver/marionette_driver/marionette.py b/testing/marionette/client/marionette/marionette.py similarity index 100% rename from testing/marionette/driver/marionette_driver/marionette.py rename to testing/marionette/client/marionette/marionette.py diff --git a/testing/marionette/client/marionette/marionette_test.py b/testing/marionette/client/marionette/marionette_test.py index 4087a84eba4..eaf41149aac 100644 --- a/testing/marionette/client/marionette/marionette_test.py +++ b/testing/marionette/client/marionette/marionette_test.py @@ -14,8 +14,7 @@ import unittest import weakref import warnings - -from marionette_driver.errors import ( +from errors import ( ErrorCodes, MarionetteException, InstallGeckoError, TimeoutException, InvalidResponseException, JavascriptException, NoSuchElementException, XPathLookupException, NoSuchWindowException, StaleElementException, ScriptTimeoutException, ElementNotVisibleException, @@ -23,10 +22,10 @@ from marionette_driver.errors import ( InvalidCookieDomainException, UnableToSetCookieException, InvalidSelectorException, MoveTargetOutOfBoundsException, FrameSendNotInitializedError, FrameSendFailureError ) -from marionette_driver.marionette import Marionette +from marionette import Marionette from mozlog.structured.structuredlog import get_default_logger -from marionette_driver.wait import Wait -from marionette_driver.expected import element_present, element_not_present +from wait import Wait +from expected import element_present, element_not_present class SkipTest(Exception): diff --git a/testing/marionette/client/marionette/runner/base.py b/testing/marionette/client/marionette/runner/base.py index ae4aa453d20..fd1e56fdb52 100644 --- a/testing/marionette/client/marionette/runner/base.py +++ b/testing/marionette/client/marionette/runner/base.py @@ -17,7 +17,7 @@ import unittest import xml.dom.minidom as dom from manifestparser import TestManifest -from marionette_driver.marionette import Marionette +from marionette import Marionette from mixins.b2g import B2GTestResultMixin, get_b2g_pid, get_dm from mozhttpd import MozHttpd from mozlog.structured.structuredlog import get_default_logger diff --git a/testing/marionette/driver/marionette_driver/selection.py b/testing/marionette/client/marionette/selection.py similarity index 100% rename from testing/marionette/driver/marionette_driver/selection.py rename to testing/marionette/client/marionette/selection.py diff --git a/testing/marionette/client/marionette/tests/unit/single_finger_functions.py b/testing/marionette/client/marionette/tests/unit/single_finger_functions.py index 5ecb14f138d..c233cec1d53 100644 --- a/testing/marionette/client/marionette/tests/unit/single_finger_functions.py +++ b/testing/marionette/client/marionette/tests/unit/single_finger_functions.py @@ -1,5 +1,5 @@ -from marionette_driver.marionette import Actions -from marionette_driver.errors import TimeoutException +from marionette import Actions +from errors import TimeoutException def wait_for_condition_else_raise(marionette, wait_for_condition, expected, script): try: diff --git a/testing/marionette/client/marionette/tests/unit/test_accessibility.py b/testing/marionette/client/marionette/tests/unit/test_accessibility.py index d0a63f855db..ee3ca9e6f1f 100644 --- a/testing/marionette/client/marionette/tests/unit/test_accessibility.py +++ b/testing/marionette/client/marionette/tests/unit/test_accessibility.py @@ -3,8 +3,8 @@ # file, You can obtain one at http://mozilla.org/MPL/2.0/. from marionette_test import MarionetteTestCase -from marionette_driver.errors import (ElementNotAccessibleException, - ElementNotVisibleException) +from errors import ElementNotAccessibleException +from errors import ElementNotVisibleException class TestAccessibility(MarionetteTestCase): diff --git a/testing/marionette/client/marionette/tests/unit/test_anonymous_content.py b/testing/marionette/client/marionette/tests/unit/test_anonymous_content.py index 0b66233c2c8..3949e29d349 100644 --- a/testing/marionette/client/marionette/tests/unit/test_anonymous_content.py +++ b/testing/marionette/client/marionette/tests/unit/test_anonymous_content.py @@ -2,12 +2,11 @@ # 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 import HTMLElement from marionette_test import MarionetteTestCase - -from marionette_driver.errors import NoSuchElementException -from marionette_driver.expected import element_present -from marionette_driver.marionette import HTMLElement -from marionette_driver.wait import Wait +from errors import NoSuchElementException +from expected import element_present +from wait import Wait class TestAnonymousContent(MarionetteTestCase): def setUp(self): diff --git a/testing/marionette/client/marionette/tests/unit/test_appcache.py b/testing/marionette/client/marionette/tests/unit/test_appcache.py index 7e0380124d7..c017de4379f 100644 --- a/testing/marionette/client/marionette/tests/unit/test_appcache.py +++ b/testing/marionette/client/marionette/tests/unit/test_appcache.py @@ -13,7 +13,7 @@ #See the License for the specific language governing permissions and #limitations under the License. -from marionette_driver.application_cache import ApplicationCache +from application_cache import ApplicationCache from marionette_test import MarionetteTestCase @@ -24,7 +24,7 @@ class AppCacheTests(MarionetteTestCase): self.marionette.navigate(test_url) app_cache = self.marionette.application_cache - status = app_cache.status + status = app_cache.status while status == ApplicationCache.DOWNLOADING: status = app_cache.status diff --git a/testing/marionette/client/marionette/tests/unit/test_capabilities.py b/testing/marionette/client/marionette/tests/unit/test_capabilities.py index 1c447060c09..128d9f99176 100644 --- a/testing/marionette/client/marionette/tests/unit/test_capabilities.py +++ b/testing/marionette/client/marionette/tests/unit/test_capabilities.py @@ -3,7 +3,7 @@ # file, You can obtain one at http://mozilla.org/MPL/2.0/. from marionette_test import MarionetteTestCase -from marionette_driver.errors import SessionNotCreatedException +from errors import SessionNotCreatedException class TestCapabilities(MarionetteTestCase): def setUp(self): diff --git a/testing/marionette/client/marionette/tests/unit/test_clearing.py b/testing/marionette/client/marionette/tests/unit/test_clearing.py index a9b3f116347..53716ccbb2a 100644 --- a/testing/marionette/client/marionette/tests/unit/test_clearing.py +++ b/testing/marionette/client/marionette/tests/unit/test_clearing.py @@ -3,7 +3,7 @@ # file, You can obtain one at http://mozilla.org/MPL/2.0/. from marionette_test import MarionetteTestCase -from marionette_driver.errors import InvalidElementStateException +from errors import InvalidElementStateException class TestClear(MarionetteTestCase): def testWriteableTextInputShouldClear(self): @@ -56,7 +56,7 @@ class TestClear(MarionetteTestCase): element = self.marionette.find_element("id","content-editable") element.clear() self.assertEqual("", element.text) - + def testTextInputShouldNotClearWhenDisabled(self): test_html = self.marionette.absolute_url("test_clearing.html") self.marionette.navigate(test_html) diff --git a/testing/marionette/client/marionette/tests/unit/test_click.py b/testing/marionette/client/marionette/tests/unit/test_click.py index 91f08314f55..d4fccbfbe91 100644 --- a/testing/marionette/client/marionette/tests/unit/test_click.py +++ b/testing/marionette/client/marionette/tests/unit/test_click.py @@ -2,10 +2,10 @@ # 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.errors import NoSuchElementException, ElementNotVisibleException +from by import By +from errors import NoSuchElementException, ElementNotVisibleException from marionette_test import MarionetteTestCase -from marionette_driver.wait import Wait +from wait import Wait class TestClick(MarionetteTestCase): diff --git a/testing/marionette/client/marionette/tests/unit/test_click_chrome.py b/testing/marionette/client/marionette/tests/unit/test_click_chrome.py index 5c6f733c38b..35e441958d3 100644 --- a/testing/marionette/client/marionette/tests/unit/test_click_chrome.py +++ b/testing/marionette/client/marionette/tests/unit/test_click_chrome.py @@ -3,7 +3,7 @@ # file, You can obtain one at http://mozilla.org/MPL/2.0/. from marionette_test import MarionetteTestCase -from marionette_driver.by import By +from by import By class TestClickChrome(MarionetteTestCase): diff --git a/testing/marionette/client/marionette/tests/unit/test_click_scrolling.py b/testing/marionette/client/marionette/tests/unit/test_click_scrolling.py index 4a88e118067..3d7f640a609 100644 --- a/testing/marionette/client/marionette/tests/unit/test_click_scrolling.py +++ b/testing/marionette/client/marionette/tests/unit/test_click_scrolling.py @@ -2,8 +2,8 @@ # 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.errors import MoveTargetOutOfBoundsException +from by import By +from errors import MoveTargetOutOfBoundsException from marionette_test import MarionetteTestCase, skip diff --git a/testing/marionette/client/marionette/tests/unit/test_date_time_value.py b/testing/marionette/client/marionette/tests/unit/test_date_time_value.py index d2fe490026a..9c89153ce5d 100644 --- a/testing/marionette/client/marionette/tests/unit/test_date_time_value.py +++ b/testing/marionette/client/marionette/tests/unit/test_date_time_value.py @@ -4,7 +4,7 @@ from marionette_test import MarionetteTestCase from datetime import datetime -from marionette_driver.date_time_value import DateTimeValue +from date_time_value import DateTimeValue class TestDateTime(MarionetteTestCase): diff --git a/testing/marionette/client/marionette/tests/unit/test_element_touch.py b/testing/marionette/client/marionette/tests/unit/test_element_touch.py index 539782ace7e..7b9f047a957 100644 --- a/testing/marionette/client/marionette/tests/unit/test_element_touch.py +++ b/testing/marionette/client/marionette/tests/unit/test_element_touch.py @@ -3,7 +3,7 @@ # file, You can obtain one at http://mozilla.org/MPL/2.0/. from marionette_test import MarionetteTestCase -from marionette_driver.errors import MarionetteException +from errors import MarionetteException class testElementTouch(MarionetteTestCase): def test_touch(self): diff --git a/testing/marionette/client/marionette/tests/unit/test_emulator.py b/testing/marionette/client/marionette/tests/unit/test_emulator.py index e69d996d27b..f330d983dba 100644 --- a/testing/marionette/client/marionette/tests/unit/test_emulator.py +++ b/testing/marionette/client/marionette/tests/unit/test_emulator.py @@ -3,8 +3,7 @@ # file, You can obtain one at http://mozilla.org/MPL/2.0/. from marionette_test import MarionetteTestCase -from marionette_driver.errors import (JavascriptException, - MarionetteException) +from errors import JavascriptException, MarionetteException class TestEmulatorContent(MarionetteTestCase): diff --git a/testing/marionette/client/marionette/tests/unit/test_errors.py b/testing/marionette/client/marionette/tests/unit/test_errors.py index 342f9b69bd4..ba5dc3f973b 100644 --- a/testing/marionette/client/marionette/tests/unit/test_errors.py +++ b/testing/marionette/client/marionette/tests/unit/test_errors.py @@ -4,9 +4,10 @@ import sys +import errors import marionette_test -from marionette_driver import errors -from marionette_driver.errors import ErrorCodes + +from errors import ErrorCodes def fake_cause(): try: diff --git a/testing/marionette/client/marionette/tests/unit/test_execute_async_script.py b/testing/marionette/client/marionette/tests/unit/test_execute_async_script.py index c55bdecff08..c527bc3171f 100644 --- a/testing/marionette/client/marionette/tests/unit/test_execute_async_script.py +++ b/testing/marionette/client/marionette/tests/unit/test_execute_async_script.py @@ -3,9 +3,7 @@ # file, You can obtain one at http://mozilla.org/MPL/2.0/. from marionette_test import MarionetteTestCase -from marionette_driver.errors import ( JavascriptException, - MarionetteException, - ScriptTimeoutException ) +from errors import JavascriptException, MarionetteException, ScriptTimeoutException import time diff --git a/testing/marionette/client/marionette/tests/unit/test_execute_isolate.py b/testing/marionette/client/marionette/tests/unit/test_execute_isolate.py index 23db19e7b3c..016ce06de66 100644 --- a/testing/marionette/client/marionette/tests/unit/test_execute_isolate.py +++ b/testing/marionette/client/marionette/tests/unit/test_execute_isolate.py @@ -3,9 +3,7 @@ # file, You can obtain one at http://mozilla.org/MPL/2.0/. from marionette_test import MarionetteTestCase, skip_if_b2g -from marionette_driver.errors import (JavascriptException, - MarionetteException, - ScriptTimeoutException) +from errors import JavascriptException, MarionetteException, ScriptTimeoutException class TestExecuteIsolationContent(MarionetteTestCase): def setUp(self): diff --git a/testing/marionette/client/marionette/tests/unit/test_execute_script.py b/testing/marionette/client/marionette/tests/unit/test_execute_script.py index da8ce6318a7..803b685e1e0 100644 --- a/testing/marionette/client/marionette/tests/unit/test_execute_script.py +++ b/testing/marionette/client/marionette/tests/unit/test_execute_script.py @@ -4,8 +4,8 @@ import urllib -from marionette_driver.by import By -from marionette_driver.errors import JavascriptException, MarionetteException +from by import By +from errors import JavascriptException, MarionetteException from marionette_test import MarionetteTestCase def inline(doc): diff --git a/testing/marionette/client/marionette/tests/unit/test_expected.py b/testing/marionette/client/marionette/tests/unit/test_expected.py index 99baec9396f..3881d4c1f24 100644 --- a/testing/marionette/client/marionette/tests/unit/test_expected.py +++ b/testing/marionette/client/marionette/tests/unit/test_expected.py @@ -4,11 +4,10 @@ import urllib -from marionette_driver import expected -from marionette_driver.by import By - +import expected import marionette_test +from by import By def inline(doc): return "data:text/html;charset=utf-8,%s" % urllib.quote(doc) diff --git a/testing/marionette/client/marionette/tests/unit/test_findelement.py b/testing/marionette/client/marionette/tests/unit/test_findelement.py index 23365bb7927..587f118fcdd 100644 --- a/testing/marionette/client/marionette/tests/unit/test_findelement.py +++ b/testing/marionette/client/marionette/tests/unit/test_findelement.py @@ -3,9 +3,9 @@ # file, You can obtain one at http://mozilla.org/MPL/2.0/. from marionette_test import MarionetteTestCase -from marionette_driver.marionette import HTMLElement -from marionette_driver.by import By -from marionette_driver.errors import NoSuchElementException, InvalidSelectorException +from marionette import HTMLElement +from by import By +from errors import NoSuchElementException, InvalidSelectorException class TestElements(MarionetteTestCase): diff --git a/testing/marionette/client/marionette/tests/unit/test_findelement_chrome.py b/testing/marionette/client/marionette/tests/unit/test_findelement_chrome.py index ee6f2e20878..4d13b1f6b29 100644 --- a/testing/marionette/client/marionette/tests/unit/test_findelement_chrome.py +++ b/testing/marionette/client/marionette/tests/unit/test_findelement_chrome.py @@ -3,9 +3,9 @@ # file, You can obtain one at http://mozilla.org/MPL/2.0/. from marionette_test import MarionetteTestCase -from marionette_driver.marionette import HTMLElement -from marionette_driver.by import By -from marionette_driver.errors import NoSuchElementException +from marionette import HTMLElement +from by import By +from errors import NoSuchElementException class TestElementsChrome(MarionetteTestCase): diff --git a/testing/marionette/client/marionette/tests/unit/test_implicit_waits.py b/testing/marionette/client/marionette/tests/unit/test_implicit_waits.py index 67da1543ab0..241dfb0926e 100644 --- a/testing/marionette/client/marionette/tests/unit/test_implicit_waits.py +++ b/testing/marionette/client/marionette/tests/unit/test_implicit_waits.py @@ -3,7 +3,7 @@ # file, You can obtain one at http://mozilla.org/MPL/2.0/. from marionette_test import MarionetteTestCase -from marionette_driver.errors import NoSuchElementException +from errors import NoSuchElementException class TestImplicitWaits(MarionetteTestCase): def testShouldImplicitlyWaitForASingleElement(self): diff --git a/testing/marionette/client/marionette/tests/unit/test_import_script.py b/testing/marionette/client/marionette/tests/unit/test_import_script.py index 0254dd8ba25..c47f98f1b52 100644 --- a/testing/marionette/client/marionette/tests/unit/test_import_script.py +++ b/testing/marionette/client/marionette/tests/unit/test_import_script.py @@ -4,7 +4,7 @@ import os from marionette_test import MarionetteTestCase -from marionette_driver.errors import JavascriptException +from errors import JavascriptException class TestImportScript(MarionetteTestCase): def setUp(self): @@ -18,14 +18,14 @@ class TestImportScript(MarionetteTestCase): def check_file_exists(self): return self.marionette.execute_script(""" let FileUtils = SpecialPowers.Cu.import("resource://gre/modules/FileUtils.jsm", {}).FileUtils; - let importedScripts = FileUtils.getFile('TmpD', ['marionetteContentScripts']); + let importedScripts = FileUtils.getFile('TmpD', ['marionetteContentScripts']); return importedScripts.exists(); """, special_powers=True) def get_file_size(self): return self.marionette.execute_script(""" let FileUtils = SpecialPowers.Cu.import("resource://gre/modules/FileUtils.jsm", {}).FileUtils; - let importedScripts = FileUtils.getFile('TmpD', ['marionetteContentScripts']); + let importedScripts = FileUtils.getFile('TmpD', ['marionetteContentScripts']); return importedScripts.fileSize; """, special_powers=True) @@ -109,7 +109,7 @@ class TestImportScript(MarionetteTestCase): self.marionette.import_script(firstjs) self.marionette.import_script(secondjs) - self.assertEqual("i'm a test function!", + self.assertEqual("i'm a test function!", self.marionette.execute_script("return testFunc();")) self.assertEqual("i'm yet another test function!", @@ -129,14 +129,14 @@ class TestImportScriptChrome(TestImportScript): def check_file_exists(self): return self.marionette.execute_async_script(""" let FileUtils = Components.utils.import("resource://gre/modules/FileUtils.jsm", {}).FileUtils; - let importedScripts = FileUtils.getFile('TmpD', ['marionetteChromeScripts']); + let importedScripts = FileUtils.getFile('TmpD', ['marionetteChromeScripts']); marionetteScriptFinished(importedScripts.exists()); """) def get_file_size(self): return self.marionette.execute_async_script(""" let FileUtils = Components.utils.import("resource://gre/modules/FileUtils.jsm", {}).FileUtils; - let importedScripts = FileUtils.getFile('TmpD', ['marionetteChromeScripts']); + let importedScripts = FileUtils.getFile('TmpD', ['marionetteChromeScripts']); marionetteScriptFinished(importedScripts.fileSize); """) diff --git a/testing/marionette/client/marionette/tests/unit/test_marionette.py b/testing/marionette/client/marionette/tests/unit/test_marionette.py index d25a800683a..4e9fd4f7e4d 100644 --- a/testing/marionette/client/marionette/tests/unit/test_marionette.py +++ b/testing/marionette/client/marionette/tests/unit/test_marionette.py @@ -2,7 +2,7 @@ # 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 import errors +import errors import marionette_test diff --git a/testing/marionette/client/marionette/tests/unit/test_navigation.py b/testing/marionette/client/marionette/tests/unit/test_navigation.py index e20733c4e7b..e95ee42467c 100644 --- a/testing/marionette/client/marionette/tests/unit/test_navigation.py +++ b/testing/marionette/client/marionette/tests/unit/test_navigation.py @@ -3,7 +3,7 @@ # file, You can obtain one at http://mozilla.org/MPL/2.0/. from marionette_test import MarionetteTestCase, skip_if_b2g, skip_if_e10s -from marionette_driver.errors import MarionetteException, TimeoutException +from errors import MarionetteException, TimeoutException class TestNavigate(MarionetteTestCase): def test_navigate(self): diff --git a/testing/marionette/client/marionette/tests/unit/test_profile_management.py b/testing/marionette/client/marionette/tests/unit/test_profile_management.py index 92b6a378286..28b9477c2e9 100644 --- a/testing/marionette/client/marionette/tests/unit/test_profile_management.py +++ b/testing/marionette/client/marionette/tests/unit/test_profile_management.py @@ -3,7 +3,7 @@ # file, You can obtain one at http://mozilla.org/MPL/2.0/. import os -from marionette_driver.errors import JavascriptException +from errors import JavascriptException from marionette_test import MarionetteTestCase class TestLog(MarionetteTestCase): diff --git a/testing/marionette/client/marionette/tests/unit/test_screen_orientation.py b/testing/marionette/client/marionette/tests/unit/test_screen_orientation.py index 06079be936d..4e5c83a8b62 100644 --- a/testing/marionette/client/marionette/tests/unit/test_screen_orientation.py +++ b/testing/marionette/client/marionette/tests/unit/test_screen_orientation.py @@ -4,7 +4,7 @@ # 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.errors import MarionetteException +from errors import MarionetteException from marionette_test import MarionetteTestCase from mozrunner.devices.emulator_screen import EmulatorScreen diff --git a/testing/marionette/client/marionette/tests/unit/test_set_window_size.py b/testing/marionette/client/marionette/tests/unit/test_set_window_size.py index bac5d713c23..044c201d2eb 100644 --- a/testing/marionette/client/marionette/tests/unit/test_set_window_size.py +++ b/testing/marionette/client/marionette/tests/unit/test_set_window_size.py @@ -2,7 +2,7 @@ # 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.errors import MarionetteException +from errors import MarionetteException from marionette_test import MarionetteTestCase class TestSetWindowSize(MarionetteTestCase): diff --git a/testing/marionette/client/marionette/tests/unit/test_simpletest_sanity.py b/testing/marionette/client/marionette/tests/unit/test_simpletest_sanity.py index 7e08be1bc66..fe51a1a47f7 100644 --- a/testing/marionette/client/marionette/tests/unit/test_simpletest_sanity.py +++ b/testing/marionette/client/marionette/tests/unit/test_simpletest_sanity.py @@ -3,9 +3,7 @@ # You can obtain one at http://mozilla.org/MPL/2.0/. from marionette_test import MarionetteTestCase -from marionette_driver.errors import (JavascriptException, - MarionetteException, - ScriptTimeoutException) +from errors import JavascriptException, MarionetteException, ScriptTimeoutException class SimpletestSanityTest(MarionetteTestCase): diff --git a/testing/marionette/client/marionette/tests/unit/test_single_finger.py b/testing/marionette/client/marionette/tests/unit/test_single_finger.py index 63afbe837cf..49a053e9518 100644 --- a/testing/marionette/client/marionette/tests/unit/test_single_finger.py +++ b/testing/marionette/client/marionette/tests/unit/test_single_finger.py @@ -3,8 +3,8 @@ # file, You can obtain one at http://mozilla.org/MPL/2.0/. from marionette_test import MarionetteTestCase -from marionette_driver.marionette import Actions -from marionette_driver.errors import MarionetteException +from marionette import Actions +from errors import MarionetteException #add this directory to the path import os import sys diff --git a/testing/marionette/client/marionette/tests/unit/test_single_finger_desktop.py b/testing/marionette/client/marionette/tests/unit/test_single_finger_desktop.py index 264b691a18f..d185b36fe08 100644 --- a/testing/marionette/client/marionette/tests/unit/test_single_finger_desktop.py +++ b/testing/marionette/client/marionette/tests/unit/test_single_finger_desktop.py @@ -1,6 +1,6 @@ from marionette_test import MarionetteTestCase -from marionette_driver.marionette import Actions -from marionette_driver.errors import MarionetteException +from marionette import Actions +from errors import MarionetteException #add this directory to the path import os import sys diff --git a/testing/marionette/client/marionette/tests/unit/test_specialpowers.py b/testing/marionette/client/marionette/tests/unit/test_specialpowers.py index 835ede56b15..aea11a878f0 100644 --- a/testing/marionette/client/marionette/tests/unit/test_specialpowers.py +++ b/testing/marionette/client/marionette/tests/unit/test_specialpowers.py @@ -3,7 +3,7 @@ # You can obtain one at http://mozilla.org/MPL/2.0/. from marionette_test import MarionetteTestCase -from marionette_driver.errors import JavascriptException, MarionetteException +from errors import JavascriptException, MarionetteException class TestSpecialPowersContent(MarionetteTestCase): @@ -15,7 +15,7 @@ class TestSpecialPowersContent(MarionetteTestCase): SpecialPowers.setCharPref("%(pref)s", "%(value)s"); return SpecialPowers.getCharPref("%(pref)s") """ % {'pref': self.testpref, 'value': self.testvalue}, special_powers=True); - self.assertEqual(result, self.testvalue) + self.assertEqual(result, self.testvalue) def test_prefs_after_navigate(self): test_html = self.marionette.absolute_url("test.html") diff --git a/testing/marionette/client/marionette/tests/unit/test_submit.py b/testing/marionette/client/marionette/tests/unit/test_submit.py index c8054277718..272f9e272b7 100644 --- a/testing/marionette/client/marionette/tests/unit/test_submit.py +++ b/testing/marionette/client/marionette/tests/unit/test_submit.py @@ -4,10 +4,11 @@ import time -from marionette_driver.by import By -from marionette_driver.errors import NoSuchElementException -from marionette_driver.wait import Wait +from by import By +from errors import NoSuchElementException from marionette_test import MarionetteTestCase +from wait import Wait + class TestSubmit(MarionetteTestCase): diff --git a/testing/marionette/client/marionette/tests/unit/test_switch_frame.py b/testing/marionette/client/marionette/tests/unit/test_switch_frame.py index 57cfe7df516..6a56c75cf08 100644 --- a/testing/marionette/client/marionette/tests/unit/test_switch_frame.py +++ b/testing/marionette/client/marionette/tests/unit/test_switch_frame.py @@ -3,8 +3,8 @@ # file, You can obtain one at http://mozilla.org/MPL/2.0/. from marionette_test import MarionetteTestCase -from marionette_driver.errors import (JavascriptException, - NoSuchFrameException) +from errors import JavascriptException +from errors import NoSuchFrameException class TestSwitchFrame(MarionetteTestCase): diff --git a/testing/marionette/client/marionette/tests/unit/test_switch_frame_chrome.py b/testing/marionette/client/marionette/tests/unit/test_switch_frame_chrome.py index 992007d1c20..d6b49cd39b1 100644 --- a/testing/marionette/client/marionette/tests/unit/test_switch_frame_chrome.py +++ b/testing/marionette/client/marionette/tests/unit/test_switch_frame_chrome.py @@ -3,8 +3,8 @@ # file, You can obtain one at http://mozilla.org/MPL/2.0/. from marionette_test import MarionetteTestCase -from marionette_driver.errors import JavascriptException -from marionette_driver.by import By +from errors import JavascriptException +from by import By class TestSwitchFrameChrome(MarionetteTestCase): def setUp(self): @@ -48,3 +48,9 @@ class TestSwitchFrameChrome(MarionetteTestCase): self.marionette.execute_async_script("foo();") except JavascriptException as e: self.assertIn("foo", e.msg) + + def test_we_can_switch_to_a_browser_frame(self): + self.assertIn("test.xul", self.marionette.get_url(), "Initial navigation has failed") + browser = self.marionette.find_element(By.ID, 'aBrowser') + self.marionette.switch_to_frame(browser) + self.assertIn("test2.xul", self.marionette.get_url(), "Switching by element failed") diff --git a/testing/marionette/client/marionette/tests/unit/test_text.py b/testing/marionette/client/marionette/tests/unit/test_text.py index 53cc340ff2a..a6ada51aa33 100644 --- a/testing/marionette/client/marionette/tests/unit/test_text.py +++ b/testing/marionette/client/marionette/tests/unit/test_text.py @@ -3,7 +3,7 @@ # file, You can obtain one at http://mozilla.org/MPL/2.0/. from marionette_test import MarionetteTestCase -from marionette_driver.keys import Keys +from keys import Keys class TestText(MarionetteTestCase): diff --git a/testing/marionette/client/marionette/tests/unit/test_timeouts.py b/testing/marionette/client/marionette/tests/unit/test_timeouts.py index 10ba6ccd4da..6e066851b0b 100644 --- a/testing/marionette/client/marionette/tests/unit/test_timeouts.py +++ b/testing/marionette/client/marionette/tests/unit/test_timeouts.py @@ -4,11 +4,8 @@ import os from marionette_test import MarionetteTestCase -from marionette_driver.marionette import HTMLElement -from marionette_driver.errors import (NoSuchElementException, - JavascriptException, - MarionetteException, - ScriptTimeoutException) +from marionette import HTMLElement +from errors import NoSuchElementException, JavascriptException, MarionetteException, ScriptTimeoutException class TestTimeouts(MarionetteTestCase): def test_pagetimeout_notdefinetimeout_pass(self): diff --git a/testing/marionette/client/marionette/tests/unit/test_typing.py b/testing/marionette/client/marionette/tests/unit/test_typing.py index 638ba2da814..969c9587e43 100644 --- a/testing/marionette/client/marionette/tests/unit/test_typing.py +++ b/testing/marionette/client/marionette/tests/unit/test_typing.py @@ -3,8 +3,8 @@ # file, You can obtain one at http://mozilla.org/MPL/2.0/. from marionette_test import MarionetteTestCase, skip_if_b2g -from marionette_driver.keys import Keys -from marionette_driver.errors import ElementNotVisibleException +from keys import Keys +from errors import ElementNotVisibleException class TestTyping(MarionetteTestCase): diff --git a/testing/marionette/client/marionette/tests/unit/test_wait.py b/testing/marionette/client/marionette/tests/unit/test_wait.py index 775b505569d..b17742249a1 100644 --- a/testing/marionette/client/marionette/tests/unit/test_wait.py +++ b/testing/marionette/client/marionette/tests/unit/test_wait.py @@ -5,12 +5,11 @@ import sys import time -from marionette_driver import errors -from marionette_driver import wait -from marionette_driver.wait import Wait +import errors +import wait from marionette_test import MarionetteTestCase - +from wait import Wait class TickingClock(object): def __init__(self, incr=1): diff --git a/testing/marionette/client/marionette/tests/unit/test_window_handles.py b/testing/marionette/client/marionette/tests/unit/test_window_handles.py index e3e192c44ec..080d6e9e965 100644 --- a/testing/marionette/client/marionette/tests/unit/test_window_handles.py +++ b/testing/marionette/client/marionette/tests/unit/test_window_handles.py @@ -3,7 +3,7 @@ # file, You can obtain one at http://mozilla.org/MPL/2.0/. from marionette_test import MarionetteTestCase, skip_if_e10s -from marionette_driver.keys import Keys +from marionette import Keys class TestWindowHandles(MarionetteTestCase): @@ -92,8 +92,6 @@ class TestWindowHandles(MarionetteTestCase): self.assertEqual(len(self.marionette.window_handles), 1) self.marionette.switch_to_window(start_tab) - # This sequence triggers an exception in Marionette:register with e10s on (bug 1120809). - @skip_if_e10s def test_tab_and_window_handles(self): start_tab = self.marionette.current_window_handle start_chrome_window = self.marionette.current_chrome_window_handle diff --git a/testing/marionette/client/marionette/tests/unit/test_window_position.py b/testing/marionette/client/marionette/tests/unit/test_window_position.py index 22001067747..70879f8d1c9 100644 --- a/testing/marionette/client/marionette/tests/unit/test_window_position.py +++ b/testing/marionette/client/marionette/tests/unit/test_window_position.py @@ -13,7 +13,7 @@ #limitations under the License. from marionette_test import MarionetteTestCase -from marionette_driver.errors import MarionetteException +from errors import MarionetteException class TestWindowPosition(MarionetteTestCase): diff --git a/testing/marionette/client/marionette/tests/unit/test_window_switching.py b/testing/marionette/client/marionette/tests/unit/test_window_switching.py index 18bd0b42658..bf689b74b3c 100644 --- a/testing/marionette/client/marionette/tests/unit/test_window_switching.py +++ b/testing/marionette/client/marionette/tests/unit/test_window_switching.py @@ -2,11 +2,10 @@ # 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 by import By +from errors import NoSuchElementException from marionette_test import MarionetteTestCase - -from marionette_driver.by import By -from marionette_driver.errors import NoSuchElementException -from marionette_driver.wait import Wait +from wait import Wait class TestWindowSwitching(MarionetteTestCase): diff --git a/testing/marionette/client/marionette/tests/unit/test_with_using_context.py b/testing/marionette/client/marionette/tests/unit/test_with_using_context.py index cfe83f531eb..d8b72a791aa 100644 --- a/testing/marionette/client/marionette/tests/unit/test_with_using_context.py +++ b/testing/marionette/client/marionette/tests/unit/test_with_using_context.py @@ -3,7 +3,7 @@ # file, You can obtain one at http://mozilla.org/MPL/2.0/. from marionette_test import MarionetteTestCase -from marionette_driver.errors import MarionetteException +from errors import MarionetteException class TestSetContext(MarionetteTestCase): diff --git a/testing/marionette/driver/marionette_driver/wait.py b/testing/marionette/client/marionette/wait.py similarity index 100% rename from testing/marionette/driver/marionette_driver/wait.py rename to testing/marionette/client/marionette/wait.py diff --git a/testing/marionette/client/requirements.txt b/testing/marionette/client/requirements.txt index fa552232a47..6cfc18169db 100644 --- a/testing/marionette/client/requirements.txt +++ b/testing/marionette/client/requirements.txt @@ -1,5 +1,4 @@ marionette-transport == 0.4 -marionette-driver == 0.1 manifestparser mozhttpd >= 0.5 mozinfo >= 0.7 diff --git a/testing/marionette/driver/marionette_driver/__init__.py b/testing/marionette/driver/marionette_driver/__init__.py deleted file mode 100644 index 23395d320d0..00000000000 --- a/testing/marionette/driver/marionette_driver/__init__.py +++ /dev/null @@ -1,8 +0,0 @@ -from marionette_driver import ( errors, by, decorators, expected, geckoinstance, - gestures, keys, marionette, selection, wait, - application_cache, date_time_value ) -from marionette_driver.by import By -from marionette_driver.date_time_value import DateTimeValue -from marionette_driver.gestures import smooth_scroll, pinch -from marionette_driver.wait import Wait - diff --git a/testing/marionette/driver/requirements.txt b/testing/marionette/driver/requirements.txt deleted file mode 100644 index 4259e197149..00000000000 --- a/testing/marionette/driver/requirements.txt +++ /dev/null @@ -1 +0,0 @@ -marionette-transport == 0.4 \ No newline at end of file diff --git a/testing/marionette/driver/setup.py b/testing/marionette/driver/setup.py deleted file mode 100644 index bd544e67665..00000000000 --- a/testing/marionette/driver/setup.py +++ /dev/null @@ -1,27 +0,0 @@ -import os -from setuptools import setup, find_packages -import sys - -version = '0.1.0' - -# dependencies -with open('requirements.txt') as f: - deps = f.read().splitlines() - -setup(name='marionette_driver', - version=version, - description="Marionette Driver", - long_description='See http://marionette-driver.readthedocs.org/', - classifiers=[], # Get strings from http://pypi.python.org/pypi?%3Aaction=list_classifiers - keywords='mozilla', - author='Auto-tools', - author_email='tools-marionette@lists.mozilla.org', - url='https://wiki.mozilla.org/Auto-tools/Projects/Marionette', - license='MPL', - packages=find_packages(), - #package_data={'marionette_driver': ['touch/*.js']}, - include_package_data=True, - zip_safe=False, - install_requires=deps, - ) - diff --git a/testing/testsuite-targets.mk b/testing/testsuite-targets.mk index d3de1eadc4e..ae6b8f402f4 100644 --- a/testing/testsuite-targets.mk +++ b/testing/testsuite-targets.mk @@ -536,10 +536,8 @@ MARIONETTE_DIR=$(PKG_STAGE)/marionette stage-marionette: make-stage-dir $(NSINSTALL) -D $(MARIONETTE_DIR)/tests $(NSINSTALL) -D $(MARIONETTE_DIR)/transport - $(NSINSTALL) -D $(MARIONETTE_DIR)/driver @(cd $(topsrcdir)/testing/marionette/client && tar --exclude marionette/tests $(TAR_CREATE_FLAGS) - *) | (cd $(MARIONETTE_DIR)/ && tar -xf -) @(cd $(topsrcdir)/testing/marionette/transport && tar $(TAR_CREATE_FLAGS) - *) | (cd $(MARIONETTE_DIR)/transport && tar -xf -) - @(cd $(topsrcdir)/testing/marionette/driver && tar $(TAR_CREATE_FLAGS) - *) | (cd $(MARIONETTE_DIR)/driver && tar -xf -) $(PYTHON) $(topsrcdir)/testing/marionette/client/marionette/tests/print-manifest-dirs.py \ $(topsrcdir) \ $(topsrcdir)/testing/marionette/client/marionette/tests/unit-tests.ini \