This removes the need to use a CPOW when sending keys to <input type=file>
elements. It was previously not possible to constructo File objects in
privileged content space, but this now appears fixed.
MozReview-Commit-ID: 8XOVsDdypwC
--HG--
extra : rebase_source : 8d4329c4c6a64ac717fc5d54dc42c8eb136f5e7f
Currently Marionette returns directly from appInfo where the webdriver
specification mandates that we return lowercase for those. See
http://w3c.github.io/webdriver/webdriver-spec.html#capabilities
MozReview-Commit-ID: 4UrOcYRuREK
--HG--
extra : rebase_source : b47a4be6f4eb17e3bf9caf8542cc2f03582df946
By default, frame scripts each have their own scope, so they can declare
global variables without causing conflicts with any other frame scripts.
The current code switches off that behaviour, meaning that the script's
scope is shared with any other frame scripts in the same frame.
This patch changes it so that each loaded frame script gets its own
scope. This works around the problem that on Windows in officially
branded builds, IPC message handlers are registered twice causing a race
condition in the IPC communication between driver.js and listener.js.
This is not a solution for fixing the core of the problem.
MozReview-Commit-ID: Fcjmi7tq5eA
--HG--
extra : rebase_source : e60adf91a98bf9ca78392ca1da804d82a0d7b885
When trying to load or unload FRAME_SCRIPT into a process we should check if we have
messageManager available to do the work or error accordingly.
MozReview-Commit-ID: 1xonnY34vI3
--HG--
extra : rebase_source : 61e681785c13e4096ca235e81f676552b9e1a629
In order to not have to manage compatibility in this area, we use the
field name proxyAutoconfigUrl that existing Selenium implementations use.
MozReview-Commit-ID: JRk6uvEbJQi
--HG--
extra : rebase_source : 637aa9eca8755b88d086e41f4a1038a246df22c8
This aligns the return types with the spec and corrects the return type to
what GeckoDriver expects.
MozReview-Commit-ID: 5A63NfpHKXC
--HG--
extra : rebase_source : f6df6893194e78792e541b9e9dd316e4d456af26
The specification says nothing about coercing to integer.
MozReview-Commit-ID: Cq5Wbo2vIAD
--HG--
extra : rebase_source : 4b953dfd48bd2227508e725dcc0cc5efc97f0bb9
Using the Selenium atom we are conflating properties and attributes which is not
thing we really want to be doing.
MozReview-Commit-ID: HdZOz1jQrwz
--HG--
extra : rebase_source : 70118dba39bb1a72e78a264d2a71beff3671f9cb
This removes the UnknowOperationError that was being thrown and returns the
property on the element that has been requested.
MozReview-Commit-ID: 2WCnBfdmit5
--HG--
extra : rebase_source : 92549bc482b3cf383bef35efa3ad10b3bcb0153e
If we have a session we are expected to return a SessionNotCreatedError as part
of step 2 of http://w3c.github.io/webdriver/webdriver-spec.html#new-session
MozReview-Commit-ID: AVmQ4Kmuczm
--HG--
extra : rebase_source : 9dfe22189bf8ac22ff2eee3df395392acedb1557
Renames instances of `elementManager' to `seenEls' for brevity. Also the
word "manager" does not really explain what purpose it fulfills.
MozReview-Commit-ID: 4EUN9utPoZS
--HG--
extra : rebase_source : 52bda0d83c50ffb96e72145ee54827c115596462
Moves ElementManager#wrapValue to the testing/marionette/element.js
module level and renames it to toJson.
MozReview-Commit-ID: GJBl2L1GRxZ
--HG--
extra : rebase_source : 5fc81a6b0ebfbd6a12557b3b746e6968c235d674
Moved ElementManager#convertWrappedArguments to the
testing/marionette/element.js module scope and renamed it to fromJson.
MozReview-Commit-ID: JMTZcG0JSUE
--HG--
extra : rebase_source : 613faca6a8c81b1ff435c538b0a7347ae548c288
Renames ElementManager to element.Store, exposing it on the
testing/marionette/element.js module. Shortens getKnownElement(uuid)
to get(uuid). Introduces new method has(uuid) to replace some unnecessary
checks in testing/marionette/driver.js and testing/marionette/listener.js.
MozReview-Commit-ID: D5qAlqrIxi
--HG--
extra : rebase_source : 22fda922e4c5f7bfcd1a5bcbcec6ae1003411535
Moves element retrieval methods from ElementManager to the
testing/marionette/element.js module itself. This means some more
work needs to be done by the caller, but avoids bloat by ensuring
ElementManager does not end up as a super-object.
MozReview-Commit-ID: 5LGe0vpSWwS
--HG--
extra : rebase_source : d7f4bd64cd1a92ad20a33496708d3f0136531d9f
The emulator code was originally hacks to allow us to instrument the emulator
from JavaScript in the B2G world. Since we no longer support this it is being
removed.
MozReview-Commit-ID: 3XDk21SFfUc
--HG--
extra : rebase_source : 63bc081c3ab37894b97b873fe142ee068b609318
Windows do not naturally belong in the seen element store, and it is
not naturally related to the scope as that of a browser.
MozReview-Commit-ID: JbQh5kDLDw
--HG--
extra : rebase_source : 075826f59a4fffc15dbbfa869eeb04b117a136da
This is a stopgap solution to work with wdspec tests. The proper solution
is to follow the steps as laid out by the specification with regards to
when existence of the current browsing context (i.e. listener) should
take place.
MozReview-Commit-ID: 5co9mfPmHir
--HG--
extra : rebase_source : c2ce333fa3ae40830934aa8f4f20873555534cab
No changes to the functionality of BrowserObj whatsoever.
MozReview-Commit-ID: JGg7eqil0qd
--HG--
extra : rebase_source : 89e2f535ec9ae17c9174e996445006e0a77111fe
In order to achieve WebDriver parity, Marionette needs the ability to
evaluate scripts in content space with lasting side-effects. This means
that state modifications should affect behaviour and state of the browsing
context, and such transgress the boundaries of the sandbox.
This patch brings a new script evaluation module that is shared between
code in chrome- and content space. This brings the number of unique
script evaluation implementations in Marionette down from six to one.
evaluate.sandbox provides the main entry-point for execution. It is
compatible with existing Marionette uses of Execute Script and Execute
Async Script commands in Mozilla clients, but also provides a new stateful
sandbox for evaluation that should have lasting side-effects.
It is not expected that Mozilla clients, such as testing/marionette/client
and the Node.js client in Gaia, should have to change as a consequence
of this change.
A substantial change to the script's runtime environment is that many
globals that previously existed are now only exposed whenever needed.
This means for example that Simple Test harness functionality (waitFor,
ok, isnot, is, &c.) is only available when using a sandbox augmented
with a Simple Test harness adapter.
Conversely, this patch does not expose marionetteScriptFinished as a
callback to asynchronous scripts for sandboxes which sandboxName parameter
is undefined, because this is what determines if the script should be
evaluated under WebDriver conformance constraints. In all other cases
where sandboxName _is_ defined, the traditional marionetteScriptFinished
et al. runtime environment is preserved.
MozReview-Commit-ID: 8FZ6rNVImuC
This allows use to be able restore the window size if we wanted to.
MozReview-Commit-ID: Kx3JH1UroI2
--HG--
extra : rebase_source : 1b41e6b488eee2b4cbbea1104323b5807890b368
In order to achieve WebDriver parity, Marionette needs the ability to
evaluate scripts in content space with lasting side-effects. This means
that state modifications should affect behaviour and state of the browsing
context, and such transgress the boundaries of the sandbox.
This patch brings a new script evaluation module that is shared between
code in chrome- and content space. This brings the number of unique
script evaluation implementations in Marionette down from six to one.
evaluate.sandbox provides the main entry-point for execution. It is
compatible with existing Marionette uses of Execute Script and Execute
Async Script commands in Mozilla clients, but also provides a new stateful
sandbox for evaluation that should have lasting side-effects.
It is not expected that Mozilla clients, such as testing/marionette/client
and the Node.js client in Gaia, should have to change as a consequence
of this change.
A substantial change to the script's runtime environment is that many
globals that previously existed are now only exposed whenever needed.
This means for example that Simple Test harness functionality (waitFor,
ok, isnot, is, &c.) is only available when using a sandbox augmented
with a Simple Test harness adapter.
Conversely, this patch does not expose marionetteScriptFinished as a
callback to asynchronous scripts for sandboxes which sandboxName parameter
is undefined, because this is what determines if the script should be
evaluated under WebDriver conformance constraints. In all other cases
where sandboxName _is_ defined, the traditional marionetteScriptFinished
et al. runtime environment is preserved.
MozReview-Commit-ID: 8FZ6rNVImuC
--HG--
extra : rebase_source : 38cc7b1e374fd42afb213133fd1a5e11bf8bdd95
This removes a hack that was left behind so to not break eideticker
and mochitests on b2g.
MozReview-Commit-ID: 3n02qaAIPyp
--HG--
extra : rebase_source : 5e81c5ee42e152681f7306185c49f4b4628ac9b6