mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-23 12:51:06 +00:00
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
This commit is contained in:
parent
e8f5082484
commit
999b92a3a5
@ -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
|
||||
|
@ -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
|
||||
|
@ -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',
|
||||
|
@ -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
|
||||
|
@ -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):
|
||||
|
@ -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):
|
||||
|
@ -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):
|
||||
|
@ -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
|
||||
|
@ -1,4 +1,3 @@
|
||||
-r mozbase_requirements.txt
|
||||
../marionette/transport
|
||||
../marionette/driver
|
||||
../marionette
|
||||
|
@ -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
|
||||
|
@ -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
|
||||
|
@ -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):
|
||||
|
@ -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
|
||||
|
@ -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:
|
||||
|
@ -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):
|
||||
|
@ -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):
|
||||
|
@ -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
|
||||
|
||||
|
@ -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):
|
||||
|
@ -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)
|
||||
|
@ -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):
|
||||
|
@ -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):
|
||||
|
@ -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
|
||||
|
||||
|
||||
|
@ -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):
|
||||
|
||||
|
@ -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):
|
||||
|
@ -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):
|
||||
|
@ -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:
|
||||
|
@ -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
|
||||
|
||||
|
||||
|
@ -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):
|
||||
|
@ -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):
|
||||
|
@ -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)
|
||||
|
@ -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):
|
||||
|
@ -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):
|
||||
|
@ -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):
|
||||
|
@ -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);
|
||||
""")
|
||||
|
||||
|
@ -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
|
||||
|
||||
|
||||
|
@ -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):
|
||||
|
@ -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):
|
||||
|
@ -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
|
||||
|
||||
|
@ -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):
|
||||
|
@ -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):
|
||||
|
||||
|
@ -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
|
||||
|
@ -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
|
||||
|
@ -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")
|
||||
|
@ -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):
|
||||
|
||||
|
@ -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):
|
||||
|
@ -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")
|
||||
|
@ -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):
|
||||
|
@ -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):
|
||||
|
@ -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):
|
||||
|
@ -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):
|
||||
|
@ -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
|
||||
|
@ -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):
|
||||
|
||||
|
@ -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):
|
||||
|
@ -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):
|
||||
|
@ -1,5 +1,4 @@
|
||||
marionette-transport == 0.4
|
||||
marionette-driver == 0.1
|
||||
manifestparser
|
||||
mozhttpd >= 0.5
|
||||
mozinfo >= 0.7
|
||||
|
@ -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
|
||||
|
@ -1 +0,0 @@
|
||||
marionette-transport == 0.4
|
@ -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,
|
||||
)
|
||||
|
@ -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 \
|
||||
|
Loading…
Reference in New Issue
Block a user