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
Bug 1123506 rewrote all the emulator handling in the listener, and a few
of the emulator related functions in testing/marionette/listener.js are
no longer needed.
MozReview-Commit-ID: 1iTjuZwcOJf
--HG--
extra : rebase_source : 088e6bbdcd52f906f2df1677a926654c1d50fc81
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
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
Implements the WebDriver pointer-interactability algorithm described in
http://w3c.github.io/webdriver/webdriver-spec.html#dfn-interactable-element.
The specification compatible behaviour is enabled only when the client
requests the capability specificationLevel >= 0.
MozReview-Commit-ID: BP60SGj49OW
--HG--
extra : rebase_source : d84d38510e28ab5e0debce2051e336e1fd3f0f86
Implements the WebDriver pointer-interactability algorithm described in
http://w3c.github.io/webdriver/webdriver-spec.html#dfn-interactable-element.
The specification compatible behaviour is enabled only when the client
requests the capability specificationLevel >= 0.
MozReview-Commit-ID: BP60SGj49OW
--HG--
extra : rebase_source : 357accaa38b44704fcaf839aa50e1e29af0b3f99
Removes the exported constants from testing/marionette/element.js and
introduces the migrates to using the element.Strategy enum consistently
throughout Marionette.
The supported strategies array passed into ElementManager's ctor has
also received some much needed attention and now actually works.
MozReview-Commit-ID: LPuDX0aishM
--HG--
extra : rebase_source : bb06ea5a25d9a0dbcd6f3e1311d31df95cd4e26d
This bug is also a dependency for scheduling Mn-e10s tests on Windows 7
(bug 1251351).
MozReview-Commit-ID: 2jE4C99d1MX
--HG--
extra : rebase_source : 96c9fad49538fdadcc8f001aeef5926e82419001
This change removes almost all the remaining uses of loadSubScript and
global scope pollution. The only remaining use is for common.js, which
is resolved by a later bug for evaluating scripts.
MozReview-Commit-ID: 96h0yLElauq
--HG--
extra : histedit_source : 70f70a8aeffef3fca18addfa3fca575a9128e11a
extra : rebase_source : c251c58a7a086c606d3d3941adfeee26ecc49504
extra : commitid : 8XlX4zVZQUN
extra : source : 6bb93562a57656e6cc744c3c901a5ec80f9ec4d8
extra : intermediate-source : ad5bf32d8fef351a0bc4d6249bd16a34aa83f548
This change removes almost all the remaining uses of loadSubScript and
global scope pollution. The only remaining use is for common.js, which
is resolved by a later bug for evaluating scripts.
MozReview-Commit-ID: 96h0yLElauq
--HG--
extra : commitid : 8XlX4zVZQUN
extra : rebase_source : a5c8057c7ce0f52dc319f2e9d0937d6a4aab84d4
extra : source : 6bb93562a57656e6cc744c3c901a5ec80f9ec4d8
extra : histedit_source : 70f70a8aeffef3fca18addfa3fca575a9128e11a
This change removes almost all the remaining uses of loadSubScript and
global scope pollution. The only remaining use is for common.js, which
is resolved by a later bug for evaluating scripts.
--HG--
extra : commitid : 8XlX4zVZQUN
extra : rebase_source : b5420c4ba5298a7e972e7b14a13325bb8ea1a540
extra : histedit_source : 70f70a8aeffef3fca18addfa3fca575a9128e11a
This fixes an instance of passing an Error prototype over the message
manager as a CPOW. We solve this by marshaling the error, which is
now done automatically by the new AsyncMessageChannel. It allows us to
create an (almost) transparent promise-based interface between chrome-
and content contexts.
The patch also makes AsyncMessageChannel reusable on both sides of the
message listener, but it's currently not used at its maximum potential
because of the way the listener is architected.
--HG--
extra : commitid : EQd5E4Digdv
extra : rebase_source : 8e0c36960759d25c73bbbc0f4f0bcb453c1028f4
extra : amend_source : 6bb6a76a8b30a5524639f8236291980b16402e6a
Turns testing/marionette/actions.js into a JS module.
--HG--
extra : commitid : 9H79Czlo1bR
extra : rebase_source : 361ba48bf1e25aff74f919b3f8d6999e3ef76209
extra : amend_source : e3d437eff976a4fd1381d5048e160c0359763d7d
This change reduces the number of content frame script message senders
from three to one by imposing a message format.
--HG--
extra : rebase_source : 2e2940eb7d095e22a60d3e6f3af44446bb425c93
Updating Marionette to click on the centre of the first client rect instead of
clicking on the centre of the bounding rect. This allows us to click on multiline
links and other items where where are mutliple DOMRects associated with
an element.
--HG--
extra : commitid : LdAoye46nTf
extra : rebase_source : d70743027886996dbea8e5cb33b4c0cdf81114b0
extra : histedit_source : 5ff0b5e7a247c810a7ff21ecbbbb714371871280