This is a significant rework of how do we compute the insertion point of a
node.
We handle pseudos in the same function instead of out of band, and also recurse
up when the parent has display: contents, which simplifies the code IMO.
MozReview-Commit-ID: 1rSfv1Tq5gO
According to sfink, mozharness is no longer used to drive hazard
builds. That means a lot of dead code that can be removed.
After this commit, there are no more references to "hazard" or
"spidermonkey" in testing/mozharness.
MozReview-Commit-ID: 8MWl8dMwRTD
--HG--
extra : rebase_source : 2156fbd13dffb22bb08b10fec2a66a9eebde8d57
These scripts are included by hazard-analysis.sh. That's their only
reference in repo.
We could probably inline these scripts. But let's start by moving them
out of mozharness since no active mozharness based task is using them.
MozReview-Commit-ID: 13oen42Txmh
--HG--
rename : testing/mozharness/scripts/spidermonkey/build.browser => taskcluster/scripts/builder/hazard-browser.sh
rename : testing/mozharness/scripts/spidermonkey/build.shell => taskcluster/scripts/builder/hazard-shell.sh
extra : rebase_source : 782f7b3f3537cfefb51b0e5f1b459c8ad0daca5b
Instead of a general socket timeout failure indicate that no hello
data has been received through the socket right after the call to
connect().
MozReview-Commit-ID: EPNiCLNyFFH
--HG--
extra : rebase_source : 05c45e99b3250f847a5c8120f23ecc9dd154212c
The getter for socket_timeout should always return the current socket
timeout from the socket instance first, and only fallback to the
private property if no socket instance exists.
This ensures that all methods will always operate on the current
socket timeout value.
Also using a timeout of 2s for receiving the hello string might be too
less for slow running builds. To prevent intermittent failures for
start_session, a good value might be 60s.
MozReview-Commit-ID: HywjFfClrRr
--HG--
extra : rebase_source : 4207e46c99445ddf7e0c4b653c865e76eb9a9c23
This change will cause Marionette to use the webdriver conformant
clickElement method instead of the legacy one by default. It means
that additional checks will be performed to ensure that the element
to click onto is visible, and not obscured by other elements. Also
it will be scrolled into view in case it is located outside of the
current view port.
Even it is used by default, the behavior can be controlled with the
"moz:webdriverClick" capability. Setting to to 'false' when creating
a new session, will cause a fallback to legacy clickElement.
MozReview-Commit-ID: E560k62Q2J9
--HG--
extra : rebase_source : 1d4d120822c6ae13a319c6c5d33e5b77b86cfdb6
Because the content frame script's clickElement function uses
the old-style despatch technique, all code lines that have the
potential of throwing must be encapsualted in try...catch blocks.
Bug 1400256 accidentally moved them outside this block, and we did
not have any tests for stale elements in web content.
This ensures errors from WebElement.fromJSON and seenEls.get get
returned to the WebDriver service in testing/marionette/driver.js.
MozReview-Commit-ID: 49qjWhXWy69
--HG--
extra : rebase_source : 3e1b639ad253c3fe7eda890de04608a925e256f5
The HTTP status for the "stale element reference" error in WebDriver
should be 404 (Not Found).
MozReview-Commit-ID: CBb7Ds8AEY3
--HG--
extra : rebase_source : 9b4309d43118730e20cb4ba17312a49cc203c58b
wdclient was the name of the old GitHub repository. The actual
Python package name is "webdriver".
MozReview-Commit-ID: FHy3iEB9aAj
--HG--
extra : rebase_source : 1f1a712fef86ab56fd9bc1f3b949e0844e9fae84
When cross-compiling geckodriver for i686-pc-windows-gnu from Linux
x86-64, this custom cargo configuration is needed. It specifies
the linker to use as well as a rustc flag for disabling backtraces
on panic, as far as I gather.
Neither of these options are necessary, of course, when we start
releasing geckodriver from Taskcluster, because we will then not
rely on cross-compilation.
MozReview-Commit-ID: 6q7wIBNrCHB
--HG--
extra : rebase_source : d71360ab043bf169871de58dfaded1a3281132e3
I'm seeing "try" in my repacks, when the underlying build has
"nightly-try". This should make the two agree.
MozReview-Commit-ID: 45yE9Qwz0v7
--HG--
extra : rebase_source : ff1ae4e50203ea032032069203558d75d348ff21
Single-locale repacks need to run aapt (--without-gradle) or Gradle
(--with-gradle). When running --with-gradle, they need to compile the
Java source code again (in order to produce a fresh R.java with
correct IDs). That compile will be part of the shipping APK, so it
needs to be configured "the same" as the underlying repacked. *This
is a significant change in behaviour, but necessary to support newer
Gradle/aapt versions, which do not maintain R.java ID mappings across
invocations.*
Part of the configuration are the secret keys and features that are
gated on them. This commit makes those secrets available to
single-locale repacks.
MozReview-Commit-ID: 4REPsIb5TgN
--HG--
extra : rebase_source : 2d23e0e0c51a61e50acf24123b316bdbb0b579ff
extra : source : a721890f7573140ca6a926e722bd3538c732dae7
It is a one-liner and doesn't need to exist in a separate make file.
MozReview-Commit-ID: 5w3eLWD0CuB
--HG--
extra : rebase_source : 15ebb63156f8b4e8d3288dfaf0d9ec2c328b5914
This also turns the tier 2 job B(n)g into tier 1, since moz.build is
still tier 1. It also pushes a lot of GeckoView related tasks into
the main builds, since they should run as part of Gradle builds.
This also removes unused tooltool manifests; the jobs that used these
manifests use only toolchain tasks now.
MozReview-Commit-ID: 2GmnJ7joCTT
--HG--
extra : rebase_source : 75cd2dfb51e0e1b510f5e618c2dc881cf5f22bf2
extra : source : 6b95b09d6afbb83ba89c47b237dfce6e15587bbe
Registering listeners for the "beforeunload" and "unload" events currently
happens on the global window and document. This actually prevents Firefox
from adding those pages to the bfcache.
The correct is to add all the listeners to the tabchildglobal, which is
the framescript itself. Also by using the capture and not the bubble phase
the unload events are correctly propagaded to our registered listeners.
MozReview-Commit-ID: 4hJjuqWsoBP
--HG--
extra : rebase_source : 619a8c936f613823dab2387efa67dc65488fbbc3
This should be functionally identical to `make -f client.mk`.
MozReview-Commit-ID: GfKHtezLBNL
--HG--
extra : rebase_source : e7965718b16d22055abdab2838e97cae63330ce9
The old code was simply running configure and manually invoking some
make targets via client.mk. These can both be done via `mach`.
As part of the change, the build targets have been consolidated. There
is still an abstraction leak here. But at least we aren't using client.mk.
MozReview-Commit-ID: 7oMXPWPZS6V
--HG--
extra : rebase_source : 6d632dc086d79a17e577da66336c77003d963f67
Building with "Linux x64 JSDCov", each suite of tests will produce a list of JSDCov artifacts (.json). This patch compresses all JSDCov artifacts into 1 zip file for each suite upon tests completion.
MozReview-Commit-ID: DaNLOQuW2lc
--HG--
extra : rebase_source : cceb912d0fe16f9921e1d13fe85d53af2abcb29c
Finding elements in the XHTML namespace will fail unless
element.isDOMElement is fixed so that it does not look at a
particular namespaceURI.
It is worth noting that, generally, the WPT element retrieval tests
are pretty awful and the new tests don't exactly match the style of
the preceding tests. This intended, because the other tests are bad.
This should be addessed individually.
MozReview-Commit-ID: 8I3VwhJirSb
--HG--
extra : rebase_source : 2de08ec68dbf8b4768708bdb733965634ac4feda
If the node variable is an object that is not null, and nodeType is
not an own property of it, node.nodeType === node.ELEMENT_NODE might be
evaluated as undefined === undefined if ELEMENT_NODE is also missing.
This will pass the condition, which is an unintended consequence.
To remedy this, we first check that nodeType indeed exists on node
before proceding.
MozReview-Commit-ID: G0eaRvwm5mv
--HG--
extra : rebase_source : 8c08e0363f26095cf672d2b11699431b1fb4ef9f
This drops the now-superfluous element.isSVGElement. SVG elements
are matched with element.isDOMElement because there is no special
need to distinguish them from other elements, apart from chrome elements.
MozReview-Commit-ID: 3AgEtyaAsPU
--HG--
extra : rebase_source : 7ec52aa9a7b7404eff5b6daf8ebe8259f06265da
This patch makes element.isDOMElement match any non-XUL element,
meaning it will henceforth match both SVG elements as well as any
custom XML namespaced element.
In the bug 1410796, Marionette does find the element, but is unable
to add it to the known web element store. This is a result of the
changes made in bug 1400256, where I introduced a set of functions
for element type recognition needed for determining which web
element abstraction to use for an element.
We use element.isDOMElement to distinguish content elements from chrome
elements, and this change consequently makes element.isSVGElement
superfluous.
MozReview-Commit-ID: AkEHm6zroKz
--HG--
extra : rebase_source : c6f101e12839241f60c8c1b3908df3a3e4a89a51
Variable appDir was being referenced before assignment. Changed the try-except-finally blocks to handle the error.
MozReview-Commit-ID: AHEeVhmPfQI
--HG--
extra : rebase_source : b0dd78f3895bb34c4e916bc0441dd9ae5e643dfc
Made this a separate commit from that which actually removes the
in-tree vendored dependencies to make it easier to review.
MozReview-Commit-ID: 9xbkM0EfOOL
--HG--
extra : rebase_source : 6686dc07a25df1a820914eb715fb733778f092cb
The Rust backtrace from geckodriver is not useful since any error
we actually return is by-definition handled by the code, and we
can probably get more information just by looking at the error type
and string.
At the same time, it runs the risk of confusing users into thinking
there was a bug in the driver when actually it's perfectly normal
handling of invalid input.
MozReview-Commit-ID: 9S5IaioA5AA
--HG--
extra : rebase_source : 0d98188c263d51402c2330a6b730752487dcc7fc
This adds a test that measure the time it takes to open the console
on a page with 100 logged messages and show something meaningful to the user.
MozReview-Commit-ID: FMx9QRKvpfl
--HG--
extra : rebase_source : d587d8258c66457a5a4cb65882c8aacaaebfa68c
The "element" field on the WebDriver:SwitchToFrame command request's
body takes a string web element reference UUID as input. This patch
changes it so that it can also take a web element JSON Object.
The old behaviour can be removed with Firefox 60.
MozReview-Commit-ID: JcTD3MRxjOe
--HG--
extra : rebase_source : f313349121787e8f68137132cac49aecebee5ba1
For user input we will want to return the appropriate invalid
argument error. For internal input using TypeError is fine.
MozReview-Commit-ID: AlOnZuhaczN
--HG--
extra : rebase_source : f16aa13b6fc53da6261594dab0c9df34d6c3df6e
This adds a global instance that can be used by invoking assertion methods directly on the imported Assert object. The test suites set the global reporter function to the one for the currently running test.
MozReview-Commit-ID: 8dksVc9o7r
--HG--
extra : rebase_source : 3e382c6d24c6019d29963811c37469cfc23b928f
Minor note:
reftests should've turned off uploadEnabled in the first place.
reftests should have unified telemetry on. It's the future.
MozReview-Commit-ID: 9spzuUAXwwP
These functions currently return sequences or arrays of elements, which
wastes cycles and memory because we spend time constructing these data
collections in cases where we only need the first element. This is
the case for WebDriver:FindElement and WebDriver:FindElementFromElement.
This patch changes the Marionette element retrieval functions to
consistently provide iterators instead of sequences when looking
up elements. Making them generator functions means the iterable
can be expanded using [...iterable] when necessary.
MozReview-Commit-ID: FZbKLuRWqgA
--HG--
extra : rebase_source : 1e7dc8c614004444f8b2476cb1a136ed36943374
The "element" field on the WebDriver:SwitchToFrame command request's
body takes a string web element reference UUID as input. This patch
changes it so that it can also take a web element JSON Object.
The old behaviour can be removed with Firefox 60.
MozReview-Commit-ID: JcTD3MRxjOe
--HG--
extra : rebase_source : 3da4b30d2689b6416d89bee838df73af40db2686
For user input we will want to return the appropriate invalid
argument error. For internal input using TypeError is fine.
MozReview-Commit-ID: AlOnZuhaczN
--HG--
extra : rebase_source : 57992fc62c08736cb24f7ee229a4c8930751e068
This prevents the geckodriver crate from being published to a
package registry like crates.io by mistake.
MozReview-Commit-ID: 7Qc9vaPhdJh
--HG--
extra : rebase_source : ec1f470a69c14c240b2cb522eb4475b22ed4a9da
A release of the webdriver crate is necessary for the release build
to pass on Travis, since testing/geckodriver/Cargo.toml cannot
depend on testing/webdriver as it is exported to the GitHub repository.
MozReview-Commit-ID: 1S2aAtg50t4
--HG--
extra : rebase_source : 53ef155537a44ef2bc141ea30a635e4144625118
Allow assert_same_element to compare web element references (JSON
Objects) with webdriver.Element and vice versa.
Tests will typically look up some element using traditional means
and use that as the trusted comparison when retrieving the same
element using the session.transport.send primitive that returns
the plain JSON Object.
MozReview-Commit-ID: 2DScnviOevb
--HG--
extra : rebase_source : d84fc331cdf2b2eb2bd36b71a184e5239b60bdff
The WPT WebDriver client currently only unmarshals responses for some
commands (notably execute_script, execute_async_script, and find.css).
For the client API we want to unmarshal all response bodies automatically.
This patch moves all JSON serialisation/deserialisation to a new
webdriver.protocol package so that it is not scattered around
the client API. It introduces specialisations of JSONEncoder and
JSONDecoder that allows web element references to be recognised
and converted to complex webdriver.Element objects.
This change means it is no longer necessary for callers to invoke
webdriver.Session._element to convert the response to a web element
as this will be done automatically on any request- and response
body to webdriver.Sesson.send_command.
An important thing to note is that HTTPWireProtocol.send does not follow
this behaviour by default. That is because session.transport.send
is used throughout WebDriver tests in WPT as a way to get the raw
JSON body without having to set up session state manually.
MozReview-Commit-ID: 5UyDAe43Hgf
--HG--
extra : rebase_source : b86495dd0dcd102e6dea87011caafad475b88723
It is more natural for the web element UUID to come first, followed
by the associated session state.
The patch also adds ctor documentation.
MozReview-Commit-ID: 5iV4SZzMeKS
--HG--
extra : rebase_source : e9f68a2a934b2c13a9d1d913204e7e3d9bce6b42
When comparing two instances of webdriver.Element we want to first
check the type, to make sure the "id" attribute is present, then
compare the web element reference UUIDs. These are supposed to be
unique across all browsing contexts.
MozReview-Commit-ID: 68PUBQxPdQ5
--HG--
extra : rebase_source : f0c52efd0db3a13ea1b90dc6c058ebee2de76e1d
When comparing two instances of webdriver.Session we want to first
check that there is a current session, then the type of the object
to compare with to make sure the "session_id" attribute is present,
then finally we compare the session IDs.
MozReview-Commit-ID: 6Ch4Uy2MEhB
--HG--
extra : rebase_source : 252fe31680c57831b122d2bb53fe133b32c322eb
This patch adds fennec staging and production relpro configs.
MozReview-Commit-ID: AuY21bqU6bl
--HG--
extra : rebase_source : 209c9d9971d2ee18a7c794e0350af90f05d6b705
In bug 1360587, we removed bouncer.apk. We accidentally removed the
mozharness config files for bouncer submission in d72b09c9228c as well.
This patch merely adds the files back.
MozReview-Commit-ID: 8c7lFr6Dpz1
--HG--
extra : rebase_source : 17ef6f2de0b0b6e1f8fde50ff3141e23cda160d3
By this changes, many queryCommandValue("justify*") return correct value.
But since we don't support mixed state of queryCommandState("justify*")
(Bug 1412167), when queryCommandValue returns correct value, queryCommandState
will return incorrectly value instead.
MozReview-Commit-ID: S6IAK8xdW2
--HG--
extra : rebase_source : d33def1ab178375266d38bc38aa1a28fa4b90919
When getting a session cookie we expect 'expiry' to be either null, or
to be missing.
MozReview-Commit-ID: JmSfrR0ypya
--HG--
extra : rebase_source : e24948efec8013b9b4c02ab9573f9c317130cd89
By silently ignoring the result from 'wait_for_port' results in a
delayed socket error, which sometimes can cause strange results
as seen on bug 1410366.
MozReview-Commit-ID: 2ptIwX6upBG
--HG--
extra : rebase_source : 9f25afacf2ce65811c51af2cf4b234c8dd1f3587
These are non-functional changes to:
* Use ES6 const/let
* Use ES6 template strings in various places
* Capitalize/fix test descriptions
MozReview-Commit-ID: CcEl42yVIQx
--HG--
extra : rebase_source : 77479514734c19535fdbcc758f6a5f6ab66b5ffc
All other tests for KeyframeEffectReadOnly live in the KeyframeEffect folder so
we should do the same for the copy constructor tests.
MozReview-Commit-ID: 3UWfCKgyUCZ
--HG--
extra : rebase_source : 5c077d1f12eca6f830e5d67779dd0dedd376576c