Commit Graph

14303 Commits

Author SHA1 Message Date
Phil Ringnalda
0413b8e93a Merge m-c to m-i
MozReview-Commit-ID: FYrJUOb5Llp
2017-01-09 18:48:50 -08:00
Phil Ringnalda
225ab0637e Backed out changeset 27f8d8e9c4dc (bug 1149966) for frequent timeouts in test_form_submission.html
MozReview-Commit-ID: K5mb2MCCiGx
2017-01-09 18:42:17 -08:00
Wes Kocher
105aea2522 Merge m-c to inbound a=merge
MozReview-Commit-ID: G24aq5fbYNd
2017-01-09 16:44:58 -08:00
Henrik Skupin
1b2e8b88a2 Bug 1328696 - Remove usage of enforce_gecko_prefs() from test_modal_dialogs.py. r=maja_zf
The preference prompts.tab_modal.enabled doesn't need a restart of Firefox. It
means there is no need to use enforce_gecko_prefs() for the tests.

MozReview-Commit-ID: 4tPBPV5v7X4

--HG--
extra : rebase_source : c9fe78f778441c66794635ebb2fdc5b8ac88c7cc
2017-01-09 10:38:15 +01:00
Masatoshi Kimura
4218f827c0 Bug 1149966 - Remove enablePrivilege calls from remaining mochitest. r=jmaher
MozReview-Commit-ID: D7KglhS4PCw

--HG--
extra : rebase_source : 4d0f848ea393a3db7e82d0e07700fe626e7caa49
extra : source : d5d6a19c81306edfaaf3e836c990bb40923623f4
2016-12-05 01:23:40 +09:00
Xidorn Quan
e7b267ea34 Bug 1328512 part 3 - Change stylo mochitest task to run all style system mochitests rather than tagged ones. r=gps
MozReview-Commit-ID: 7rUHpTFQflF

--HG--
extra : rebase_source : 72a62e1a582afc59ef6cc9c1488862efb14dedc8
2017-01-04 16:37:08 +11:00
Andrew McCreight
542343e117 Bug 1325438 - Remove leak checking whitelist for tests/dom/xhr/tests. r=jmaher
MozReview-Commit-ID: 48elhM564zJ

--HG--
extra : rebase_source : b1f665ab81afa26ed4ec06aa021251636bb462a1
2017-01-06 13:15:53 -08:00
Ryan VanderMeulen
1e6f972917 Merge inbound to m-c. a=merge 2017-01-07 11:22:47 -05:00
Masayuki Nakano
b2778c3a90 Bug 1272623 part.3 HTMLEditRules::ReapplyCachedStyles() shouldn't set style to TypeInState if it's currently applied r=smaug
The target node of HTMLEditRules::ReapplyCachedStyles() may be styled with its parent.  When HTMLEditRules::ReapplyCachedStyles() is called, it shouldn't restore another style cache if it's already specified in current DOM tree.

MozReview-Commit-ID: DKCpQ8YyW7

--HG--
extra : rebase_source : 854b4cc6382f5357919bce1e106e71fe66b15444
2017-01-06 22:35:48 +09:00
Andrew McCreight
d0c224741e Bug 1325277 - Re-enable leak checking for dom/animation/test/css-animations. r=ahal
MozReview-Commit-ID: LSlEw5tCcTx

--HG--
extra : rebase_source : 9b78fd1eeea1df1553cf2741f3fcd68b0bbf052e
2017-01-06 11:04:41 -08:00
Jarda Snajdr
53fd6f6e23 Bug 1328553 - Part 2: Add a netmonitor.requestsFinished timing to DAMP tests r=jryans
MozReview-Commit-ID: 1v7yIUfEwan

--HG--
extra : rebase_source : 9092bea6ac3d59952b07b316450709597f180e61
2017-01-04 11:15:12 +01:00
Andreas Tolfsen
180328b651 Bug 1326534 - Rename sessionCapabilities variable for brevity; r=whimboo
MozReview-Commit-ID: KGYk2CgwERy

--HG--
extra : rebase_source : b1090c3de72ae61696522c47849da269bea90fb8
2016-12-31 12:32:14 +00:00
Andreas Tolfsen
035850381f Bug 1326534 - Use session.Capabilities representation in listener; r=automatedtester
Capabilities are sent to the content frame script as a JSON blob.
We can re-parse that in the listener to make use of the same complex
object representation there.

Because the listener is comprised of a set of top-level functions and
not an object prototype, we cannot reuse the same pointer/getter trick
as in testing/marionette/driver.js.  However, we can change this later
when we do introduce more robust code organisation to this file.

MozReview-Commit-ID: 7PpholLqtF

--HG--
extra : rebase_source : 93b94678ac2184255b1c708103eb5cf44f9d2266
2016-12-31 12:30:49 +00:00
Andreas Tolfsen
2c29d0b5e6 Bug 1326534 - Reset session capabilities state on teardown; r=whimboo
This change resets the session ID after all other state has been cleared,
and also reinitialises `GeckoDriver#sessionCapabilities`, which was not
done before.

MozReview-Commit-ID: Jb40CXuX8h1

--HG--
extra : rebase_source : 226875ea929f0e7e471fe58499f76313fc60947e
2016-12-31 12:28:19 +00:00
Andreas Tolfsen
c67cbf8a8c Bug 1326534 - Deploy WebDriver conforming capabilities in Marionette; r=automatedtester,maja_zf,whimboo
This change removes session capability processing
from testing/marionette/driver.js and replaces it with
testing/marionette/session.js and `session.Capabilities`.

Session timeout durations used to be stored in properties
exposed directly on the `GeckoDriver` prototype, but these are now
represented by `GeckoDriver#timeouts`, which is a pointer (getter) of
`GeckoDriver#sessionCapabilities#timeouts`.  The same is true for other
session-scoped state.

Since capabilities parsing is not unique to starting a new session,
the errors thrown by `session.Capabilities.fromJSON` are re-thrown
in `GeckoDriver#newSession` since it is required that we return a
`SessionNotCreatedError` on parsing them during session creation.

MozReview-Commit-ID: I3Xu2v71n4S

--HG--
extra : rebase_source : 40cef31adf238bef021a7c7c2713016a34f35920
2016-12-31 12:27:13 +00:00
Andreas Tolfsen
c276b917c4 Bug 1326534 - Rewrite capabilities parsing in Marionette; r=automatedtester
This patch provides a (nearly) WebDriver conforming implementation
of capabilities in Marionette.  The work remaining is pending further
clarification in the specification.

Capabilities are represented internally as a complex object provided
by `session.Capabilities`.  Timeouts and proxy configuration are also
represented by the similar complex objects `session.Timeouts` and
`session.Proxy`, respectively.

The capabilities stored in `GeckoDriver#sessionCapabilities` are the
result of parsing user-provided desired- and required capabilities.
WebDriver now uses `firstMatch` and `alwaysMatch` primitives for
capabilities, but as this is considered a wider breaking change, the
move to these primitives will be done at a later stage.  It’s prudent
to point out that the base techniques used with the new primitives
are similar to those implemented for `desiredCapabilities` and
`requiredCapabilities` in this patch, and that the work needed to adapt
them is considered trivial.

When capabilities are presented back to the user (the so called processed
capabilities), we call the `toJSON` implementation on the complex objects.
`session.Capabilities#toJSON` calls the internal function `marshal`
which ensures empty fields are dropped.  `marshal` can be considered to
be a specialisation of the standard library `JSON.stringify`, which also
calls `toJSON` on entry values if they provide this function.

The changeset overall also provides a much deeper level of testing of
WebDriver capabilities.

MozReview-Commit-ID: 97xGt3cnMys

--HG--
extra : rebase_source : 98e0bde3fdfd811775d195b488cb1255f61e5772
2016-12-31 12:21:34 +00:00
Andreas Tolfsen
0a79a38232 Bug 1326534 - Correct capability wrapping in tests; r=automatedtester
Capabilities should be sent in either a `desiredCapabilities` or a
`requiredCapabilities` block inside `capabilities`:

	{capabilities: {requiredCapabilities: {acceptInsecureCerts: true}}}

Marionette currently accepts capabilities in the top-level dictionary,
but this is not conforming to the WebDriver.

MozReview-Commit-ID: 9JWjvPKBp6S

--HG--
extra : rebase_source : 88a12dcba275d6eedc5640bd3a0033b6dbd1d86d
2016-12-30 14:12:53 +00:00
Andreas Tolfsen
b2889c31fc Bug 1326534 - Propagate stacktraces for WebDriver errors; r=automatedtester
When we currently create new WebDriver errors we throw away the stacktrace
generated by `WebDriverError`'s prototype, `Error`.  This change stores
the stacktrace, which will cause it to be serialised and returned to
the client.

This change is not as valuable as storing the stacktraces of internal
errors, but brings symmetry to our error handling and may be useful if
only to navigate to the source of an error.

MozReview-Commit-ID: LCFMwKxxcTp

--HG--
extra : rebase_source : 56947805f29000a64c2daef0fd774ea90330c09e
2016-12-30 13:07:54 +00:00
Andreas Tolfsen
9a4394f2c5 Bug 1326534 - Lint a few statements in driver.js; r=automatedtester
No functional changes.

MozReview-Commit-ID: FP9p9tPr8Ce

--HG--
extra : rebase_source : fb3e43203b417b119df2c0975c15aa95c1b16408
2016-12-30 12:43:36 +00:00
Andreas Tolfsen
52426eb1ab Bug 1326534 - Add assert.in for own properties; r=automatedtester
The implementation of the new library function `assert.in` is analogous
to Python's `unittest.TestCase.assertIn`.

MozReview-Commit-ID: 1pjS9ttPXgo

--HG--
extra : rebase_source : 3f4121226d65f127fdf0c990915483659f3a7f93
2016-12-30 11:39:22 +00:00
Andreas Tolfsen
4a5f5aabaf Bug 1326534 - Add test for assert.array; r=automatedtester
MozReview-Commit-ID: IWUnhCgPp1R

--HG--
extra : rebase_source : 4cc54031f9e34cf210229bcd394747e4bafcbd8f
2016-12-30 11:30:05 +00:00
Andreas Tolfsen
a35ff231b0 Bug 1326534 - Preserve stacks when passing error protos to WebDriverError; r=automatedtester
The `stack` argument to `WebDriverError` has never been in use.  Following
the API of the `Error` prototype, this changes its constructor to take
one argument which can either be a string of an `Error`.

When internal errors are thrown in Marionette, they are usually
wrapped in `WebDriverError` but we currently lose track of its stack.
This preserves the wrapped error's stacktrace by setting the `stack`
property.  Practice have found that they are very useful to return to
the client, as they are currently only printed to stdout.

MozReview-Commit-ID: 9sTdP4TntIc

--HG--
extra : rebase_source : f14197a1c8700215ce3d0edc7078c9f568b80ec4
2016-12-30 11:26:30 +00:00
Andreas Tolfsen
de884b68a6 Bug 1326534 - Exclude array and null from being counted as objects; r=automatedtester
Calling `typeof` on arrays or null in JavaScript returns `"object"`,
and a safer check is to rely on `Object.prototype.toString`.

MozReview-Commit-ID: 5VxXf2ByoEx

--HG--
extra : rebase_source : 4d1fe95a75343964836e670d0ceffa6ce680e390
2016-12-30 11:21:27 +00:00
Andreas Tolfsen
c8b477dd83 Bug 1326534 - Correct tests for mandated and supported capabilities; r=automatedtester
MozReview-Commit-ID: 932AoNlBtwt

--HG--
extra : rebase_source : b2baf4ad234d63e8fbc146ce202319cd35f50395
2016-12-20 15:01:18 +00:00
James Graham
5f011d137e Bug 1328823 - Bump mozprocess version number to 0.24 for release, r=ahal
MozReview-Commit-ID: 251xwdA7rxc

--HG--
extra : rebase_source : 2662ed18044da7173eaaeca941c0e72b3f9ba089
2017-01-06 15:39:55 +00:00
Iris Hsiao
7e248d8cc9 Merge mozilla-central to autoland 2017-01-06 11:13:22 -05:00
Henrik Skupin
3f2001d14f Bug 1326047 - Skip unit tests which rely on an instance but Marionette doesn't manage the process. r=ato,maja_zf
Unit tests which do a restart/quit of the application should not be run if Marionette
doesn't handle the instance. Otherwise Marionette is not able to launch the application
again for further tests.

MozReview-Commit-ID: 8mKylM0r4dM

--HG--
extra : rebase_source : 8d1853c376fe36c4f779b3d417edb2dbb829a1a3
2017-01-04 13:04:55 +01:00
Henrik Skupin
3aa44ab017 Bug 1326047 - Remove usage of enforce_gecko_prefs() from test_shadow_dom.py. r=ato
Flipping the preference "dom.webcomponents.enabled" doesn't require a restart.
As such there is no need to use enforce_gecko_prefs().

MozReview-Commit-ID: 6sl1xycwWII

--HG--
extra : rebase_source : 6444825d3addf6a71f1cb495c1dfb79b0fa7c1d4
2017-01-06 09:43:43 +01:00
Maja Frydrychowicz
b70dbe097b Bug 1328411 - Enforce relationship between e10s runner option and browser appinfo; r=automatedtester
MozReview-Commit-ID: KMOv9uNfjXH

--HG--
extra : rebase_source : 7e51891aa32acb7a59e9a26679155090ceff7ca3
2017-01-04 12:06:36 -05:00
Maja Frydrychowicz
4608e9b8ca Bug 1328411 - Move e10s prefs setup to BaseMarionetteTestRunner; r=automatedtester
This allows the |e10s| argument in BaseMarionetteTestRunner to enable e10s in
the browser without depending on |BaseMarionetteArguments.verify_usage|.

Unlike other args like |jsdebugger|, the |e10s| argument is found in both
BaseMarionetteArguments and BaseMarionetteTestArguments, so it's more
intuitive to pass it along and perform all the associated setup
in BaseMarionetteTestRunner.

MozReview-Commit-ID: JCvxdazjq8p

--HG--
extra : rebase_source : 9a89733e9ba0ffce9060f01bd04115b796ff8b08
2017-01-04 12:06:06 -05:00
Maja Frydrychowicz
d03992ee9b Bug 1328411 - Log e10s status in Marionette runner based on appinfo; r=automatedtester
Previously, this log message was based on self.e10s, which only reflects the
option passed into Marionette runner, not what is actually happening in the browser.

MozReview-Commit-ID: GY2AaBKBA1h

--HG--
extra : rebase_source : 735ca90efdc86b3cc5f6ce81e81845009acfbbd2
2017-01-03 22:23:03 -05:00
Andreas Tolfsen
a6470e1da2 Bug 1328676 - Focus web content on starting new session and navigating; r=automatedtester
When a new Marionette session is started, the web content frame (currently
selected <xul:browser> element) is not in focus, causing issues such
as https://github.com/mozilla/geckodriver/issues/394.

This changes the current web content to be selected upon top-level
browsing context navigation and the creation of new sessions.

MozReview-Commit-ID: EgG9gRHtwOA

--HG--
extra : rebase_source : 79c89e2a6d35badf454645bbfb5197a94bb1f980
2017-01-04 19:38:34 +00:00
Andreas Tolfsen
2efb1a7465 Bug 1328676 - Document some particulars of browser.Context; r=automatedtester
browser.Context has an awful API and this is a small step in the direction
of mitigating some common misconceptions about its internal state.

MozReview-Commit-ID: Bl5197GiSEL

--HG--
extra : rebase_source : 8dfb5a38e51eaa0721053d9f77d15429ccd94051
2017-01-04 19:37:13 +00:00
Andreas Tolfsen
e6cadbdcc2 Bug 1213875 - Test scroll override behaviour; r=whimboo
MozReview-Commit-ID: 7SjBvfY4qel

--HG--
extra : rebase_source : a4fdbfd2bc8c334ba0f16de4f8b378ec69131461
2016-12-20 14:31:43 +00:00
Andreas Tolfsen
10bce4d4f0 Bug 1213875 - Add scroll argument to Marionette client; r=whimboo
MozReview-Commit-ID: Jg9DW1TDmNS

--HG--
extra : rebase_source : 7eabba9eede089e84279f338029d40512ff30540
2016-12-20 14:31:18 +00:00
Andreas Tolfsen
2d255984aa Bug 1213875 - Add ability to not scroll into view element on screen capture; r=whimboo
Implements a `scroll` argument for choosing the scroll into view behaviour
when taking screen captures of elements.

https://w3c.github.io/webdriver/webdriver-spec.html#take-element-screenshot

MozReview-Commit-ID: BOKBrKqQ916

--HG--
extra : rebase_source : 290f9a6a7c64c0f2932128679a84044138d96b6c
2016-12-20 14:30:48 +00:00
Andreas Tolfsen
c48ea8d3bb Bug 1213875 - Lint arguments in capture module; r=whimboo
MozReview-Commit-ID: EowxaYVwMxm

--HG--
extra : rebase_source : e99562b1cc84b302b52eb66b6f8fe45649b19d4c
2016-12-20 14:26:58 +00:00
Wes Kocher
fb74e5d705 Backed out changeset e0378b0c798e (bug 1325801) for bustage a=backout 2017-01-04 18:21:32 -08:00
Maja Frydrychowicz
a6ebb1c134 Bug 1328654 - Clean up after Marionette runner in MarionetteHarness; r=whimboo
This fixes the case where the call to runner.run_tests() raises
an exception before any tests start, thus leaving a
browser instance running.

MozReview-Commit-ID: LFcCZcJJsgf

--HG--
extra : rebase_source : 99a55b534a5260cb791d9dca24364592d24d5d72
2017-01-04 10:09:54 -05:00
Chris Manchester
79a952a215 Bug 1325801 - Fix intermittent failure staging cppunittests. r=mshal
Dumping symbols can interfere with staging cppunittests in case calling
objcopy from the symbol dumping script coincides exactly with calling
objcopy when staging cppunittests when the two are run in parallel. This
makes dumping symbols depend on staging cppunittests.

MozReview-Commit-ID: Hgi1zyIZE7K

--HG--
extra : rebase_source : 1afda6854cd1ff0a651cd9fa1bde17fc0c797b01
2017-01-04 12:56:14 -08:00
Mark Banner
39df62d9dc Bug 1328338 - Fix more no-undef eslint issues in toolkit/ and browser/. r=mossop
MozReview-Commit-ID: 78dXLYVW1gC

--HG--
extra : rebase_source : 4d2c50697307177c76a71ca7989863f01b05290b
2017-01-03 11:55:24 +00:00
Carsten "Tomcat" Book
98048f1496 Merge mozilla-central to autoland 2017-01-04 16:20:18 +01:00
Carsten "Tomcat" Book
b4e6d275b7 merge mozilla-inbound to mozilla-central a=merge 2017-01-04 16:09:56 +01:00
Andrew Halberstadt
e5be7e718f Bug 1328549 - Fix mochitest import error when running via mach, r=jmaher
MozReview-Commit-ID: DulWm9tOIBd

--HG--
extra : rebase_source : 0f73990bd600b2ba635ca97e3c04bc6309630a98
2017-01-04 09:39:42 -05:00
Phil Ringnalda
8b917c2dd0 Merge m-c to autoland 2017-01-03 18:45:51 -08:00
Phil Ringnalda
82ebc0c5ea Merge m-i to m-c, a=merge
MozReview-Commit-ID: FEe5yZfka5J
2017-01-03 18:40:26 -08:00
Sebastian Hengst
d3f1bf94e1 Backed out changeset 2bd53e4e662b (bug 1303113) for various test failures in debug tests with e10s. r=backout 2017-01-03 20:53:59 +01:00
Tim Nguyen
97afb532ff Bug 1322938 - Put <dialog> element behind preference. r=smaug
MozReview-Commit-ID: 3thJ5B7Znwo
2016-12-23 16:01:50 +01:00
Tim Nguyen
a4d4935ae7 Bug 1322938 - Update <dialog> element Web Platform Tests expected results. r=smaug
MozReview-Commit-ID: LPpjDkNI6n8
2016-12-23 16:01:50 +01:00
Gabor Krizsanits
6df27d5c23 Bug 1303113 - Turn e10s-multi on in Nightly. r=me 2017-01-03 18:14:50 +01:00