Граф коммитов

3391 Коммитов

Автор SHA1 Сообщение Дата
Andreas Tolfsen cb8c6e7e1d Bug 1454876 - Correct marionette.enabled pref doc. r=maja_zf
The documentation for the marionette.enabled preference is wrong: it
claims that it is used for disabling the Marionette XPCOM component,
but in reality it starts and stops the TCP server.

MozReview-Commit-ID: 8oQz8HjPnii

--HG--
extra : rebase_source : 7771f02e18457bc5e567553ca921995d95c40bdd
2018-04-18 08:05:26 +01:00
James Graham 4daf082666 Bug 1452643 - Update wptserve args in marionette runner, r=me ON A CLOSED TREE
MozReview-Commit-ID: DvCYUNlX3VQ
2018-04-15 19:26:00 +01:00
Emilio Cobos Álvarez 9509cd7e32 Bug 1453789: Remove Element.createShadowRoot. r=smaug
MozReview-Commit-ID: Hgxbp1Icgvh
2018-04-13 20:51:55 +02:00
Andreas Tolfsen 1df257e9fc Bug 1453381 - Update Marionette test documentation. r=whimboo
MozReview-Commit-ID: 2BBYPcGIgek

--HG--
extra : rebase_source : 337b6204771f271e47c8cad22ad6b027000b9a74
2018-04-11 23:44:44 +01:00
Andreas Tolfsen 1f71437e6b Bug 1453381 - Add docs for running Marionette xpcshell tests. r=whimboo
This duplicates documentation under testing/marionette/doc, but
can be useful when inspecting the directory.

MozReview-Commit-ID: 7vuUze1SFib

--HG--
extra : rebase_source : 94f2f4de916e576deffe1b3a23beff392b7bb594
2018-04-11 20:53:50 +01:00
Andreas Tolfsen d5dfaa44a7 Bug 1453381 - Fix lint violations in Marionette xpcshell tests. r=whimboo
This patch is partly machine generated and partly massaged by hand
to achieve a satisfactory result.

MozReview-Commit-ID: IG46e93KoOb

--HG--
extra : rebase_source : 02f8fa6ec28a737a4151a757f75cf7ae36427e30
2018-04-11 20:26:53 +01:00
Andreas Tolfsen 2f6356ce4f Bug 1453381 - Enable eslint for Marionette xpcshell tests. r=whimboo
There are currently two exceptions from the normal linting rules
that applies to Marionette xpcshell unit tests:

  - We use camel-casing for our test names.

  - We have many lines longer than 78 characters.

MozReview-Commit-ID: 4MykQujk9lR

--HG--
extra : rebase_source : f73e1a8d205eb34d1463f4805ba0fa806f150081
2018-04-11 20:27:49 +01:00
Andreas Tolfsen 67fe97531f Bug 1453381 - Move Marionette xpcshell tests to subdirectory. r=whimboo
In order to more easily facilitate linting of xpcshell unit tests,
this patch moves the tests to the test/unit subdirectory.

MozReview-Commit-ID: K1rtmreFWRL

--HG--
rename : testing/marionette/test_action.js => testing/marionette/test/unit/test_action.js
rename : testing/marionette/test_assert.js => testing/marionette/test/unit/test_assert.js
rename : testing/marionette/test_browser.js => testing/marionette/test/unit/test_browser.js
rename : testing/marionette/test_cookie.js => testing/marionette/test/unit/test_cookie.js
rename : testing/marionette/test_dom.js => testing/marionette/test/unit/test_dom.js
rename : testing/marionette/test_element.js => testing/marionette/test/unit/test_element.js
rename : testing/marionette/test_error.js => testing/marionette/test/unit/test_error.js
rename : testing/marionette/test_evaluate.js => testing/marionette/test/unit/test_evaluate.js
rename : testing/marionette/test_format.js => testing/marionette/test/unit/test_format.js
rename : testing/marionette/test_message.js => testing/marionette/test/unit/test_message.js
rename : testing/marionette/test_navigate.js => testing/marionette/test/unit/test_navigate.js
rename : testing/marionette/test_session.js => testing/marionette/test/unit/test_session.js
rename : testing/marionette/test_sync.js => testing/marionette/test/unit/test_sync.js
rename : testing/marionette/unit.ini => testing/marionette/test/unit/xpcshell.ini
extra : rebase_source : b77cdb754ddc90d1c4ff0e2f6a8dead5168677fe
2018-04-11 19:54:42 +01:00
Andreas Tolfsen 732c8b496c Bug 1453009 - Remove collection tests from Marionette. r=whimboo
Now that we test collections upstream in WPT, the overlapping tests
can be removed from the Mn test suite.

MozReview-Commit-ID: DJZHeKs8FDo

--HG--
extra : rebase_source : 3170081c4054141ab6e39d69865f44a3d55f0385
2018-04-10 19:31:25 +01:00
Andreas Tolfsen 3e389d5b45 Bug 1452597 - Remove debug_script functionality for injected scripts. r=maja_zf
The WebDriver:ExecuteScript and WebDriver:ExecuteAsyncScript commands
accepts a "debug_script" parameter that attaches an error handler
on the WindowProxy in the sandbox.

This used to be necessary because the error handler used to be
attached to the content window instead of the sandbox.

MozReview-Commit-ID: ImRVkC5T75O

--HG--
extra : rebase_source : c13c33b4d708879f66bd906f431157720842690c
2018-04-09 13:13:18 +01:00
Andreas Tolfsen 50514918d4 Bug 1452483 - Preserve stacktrace from sandbox evaluation. r=maja_zf
Now that the correct filename and line number is being passed to
Cu.evalInSandbox, the stacktrace of the thrown error is correct.
JavaScriptError uses the line number to index the injected source
script, but the line number refers to the file represented by the
"filename" parameter and not to the script.

This effectively means that the line numbers in the produced
stacktrace are wrong because line number 0 was hard-coded as an
argument to Cu.evalInSandbox.

This patch harmonises the stacktraces returned from
WebDriver:ExecuteScript and WebDriver:ExecuteAsyncScript with
stacktraces from normal JavaScript errors, by removing some extra clutter.

MozReview-Commit-ID: 9nm6HeA4YVJ

--HG--
extra : rebase_source : e0f6e0c9595456fb59123adc98cea6d3d32abce3
2018-04-09 11:45:49 +01:00
Andreas Tolfsen edb0e19511 Bug 1452483 - Use relative path to source file for injected scripts. r=maja_zf
The basename is not sufficient to locate the file.  Using the file's
relative path will match the behaviour of JavaScript stacktraces.

We can't use relative paths on Windows because the source file may
exist on another disk drive, and on Windows you cannot make relative
paths across disk drives because they don't share the same root.

MozReview-Commit-ID: 4EPITa2kH6J

--HG--
extra : rebase_source : 44781ee506b5150b8e48e8a6b63142badee5b172
2018-04-09 11:43:08 +01:00
Andreas Tolfsen 578b658ea0 Bug 1452483 - Strip whitespace from injected scripts. r=maja_zf
The injected script may contain a lot of whitespace padding on
either side of the string when using multi-line strings ("""foo""")
in Python.  To improve readability of the trace log we can strip
it off before sending it to Marionette.

MozReview-Commit-ID: 2cNlwVzqWTK

--HG--
extra : rebase_source : 1ec06523a6e99e188b8cb7b616b357c1e9dea125
2018-04-09 11:41:46 +01:00
Andreas Tolfsen 989c6a2abd Bug 1452483 - Set correct line number for JS evaluation. r=maja_zf
Marionette incorrectly sets the JavaScript context line number to 0.
The line number is provided to us in in the input, so we should
use this.  The default fallback if line is not provided is 0 as before.

MozReview-Commit-ID: 8gOt9r4awee

--HG--
extra : rebase_source : 3d268fff56554c76cbcb831dd2c8665dffd2ca08
2018-04-08 17:44:55 +01:00
Henrik Skupin 48c0225a24 Bug 1434926 - Release marionette_driver 2.6.0 and marionette_harness 4.4.0. r=ato
DONTBUILD

MozReview-Commit-ID: F5dIk9HYN9L

--HG--
extra : rebase_source : f28f48434899e7e38c0b5e2a312205b932305cde
2018-04-11 10:46:38 +02:00
Andreas Tolfsen 7f65fc5fad Bug 1452487 - Remove directInject functionality in evaluate.sandbox. r=maja_zf
The evaluate.sandbox function accepts a directInject argument,
which is a relic from Marionette's B2G past when it did not support
evaluating scripts with lasting side-effects.

The API documentation in GeckoDriver#execute_ mentions directInject as a
valid parameter, but it is not picked up or passed on to evaluate.sandbox.
This effectively means the directInject functionality is unused.

MozReview-Commit-ID: 3rYjRQ2R5GV

--HG--
extra : rebase_source : b0c58077de0d7320d2bd1cc55d1af1b959ecaccf
2018-04-08 18:03:29 +01:00
Henrik Skupin 340ebbc7bd Bug 1451727 - [marionette] Remove deprecated WebDriver commands. r=ato
Removes the following deprecated WebDriver commands from marionette
client: Element.size, Element.location, set_script_timeout,
set_search_timeout, and set_page_load_timeout.

It doesn't touch get_window_position, set_window_position,
window_size, and set_window_size because those are covered
by bug 1348145.

MozReview-Commit-ID: 9b74toO1Rzm

--HG--
extra : rebase_source : a9a73cf8cc36ed3d428ce1c7c54b83b9f0f4a63c
2018-04-06 12:12:24 +02:00
Henrik Skupin d8fa75315b Bug 1451727 - [marionette] Remove unused execute_js_script method. r=ato
MozReview-Commit-ID: 3tkQmmRZfbd

--HG--
extra : rebase_source : 02ca72d05f8b5dd8f16bff98ea1ff9fdd50ec98a
2018-04-06 11:15:51 +02:00
Henrik Skupin 105a8df3da Bug 1451727 - [marionette] Update vendor specific commands to use custom prefixes. r=ato
All chrome context related commands have to use the "Marionette"
prefix. For those commands which accidentally have been put under
the "WebDriver" prefix a fallback to the old command is needed
in the Marionette client.

Also update related comments about possible removal dates.

MozReview-Commit-ID: IZLL6pineSO

--HG--
extra : rebase_source : 7e4cbe604d1f0b35cce01173a438b898658018b3
2018-04-05 21:23:57 +02:00
Henrik Skupin ff8a4a9bc2 Bug 1451727 - [marionette] Update WebDriver specific commands to use the "WebDriver" prefix. r=ato
MozReview-Commit-ID: 57wk5BD8F2m

--HG--
extra : rebase_source : 538165f66d5b21e259696077ef3abf7a8a6a74c8
2018-04-05 18:08:48 +02:00
Henrik Skupin c15c7802d7 Bug 1451727 - [marionette] Add "WebDriver:AcceptAlert" in favor of "WebDriver:AcceptDialog". r=ato
To be consistent with the spec the command should be named
"WebDriver:AcceptAlert".

MozReview-Commit-ID: HGB9hJPAvcU

--HG--
extra : rebase_source : bbf3d657901784e1ab6e096edf1b20a5c43b0176
2018-04-05 15:50:28 +02:00
Henrik Skupin eefc844456 Bug 1368767 - Fix race condition in test_set_location_through_execute_script. r=ato
Using get_url() to wait for a page load to be done doesn't work because
it already returns when the location bar gets updated. Instead wait for
a known element of the page.

MozReview-Commit-ID: CdYux8sTAiP

--HG--
extra : rebase_source : 72d3313c3f3022d94487aa1fedc8538e5c2d8fbb
2018-04-09 16:07:15 +02:00
Andreas Tolfsen d22026fa5d Bug 1452479 - Include timeout duration in ScriptTimeoutError. r=whimboo
We don’t currently log what the script timeout was when throwing
ScriptTimeoutError.  It would provide more value to the user to
include the timeout duration than to record "Timed out" as we do
currently.

MozReview-Commit-ID: 3DM1Xer3Qbz

--HG--
extra : rebase_source : 1c4dfc96957dd9b64562e8354526da1b7350e6cf
2018-04-08 17:23:14 +01:00
Dão Gottwald f8110c1b6a Bug 1451709 - Remove code for the "Restore Tabs From Last Time" button in the tab bar. r=mikedeboer
MozReview-Commit-ID: JMmkE6axBBK

--HG--
extra : rebase_source : 2449c9fd6fe8f59280dbdfe5a1a55bcd2867a665
2018-04-05 14:02:55 +02:00
Andreea Pavel 70b9a8fbc0 Merge mozilla-central to autoland a=backout 2018-04-06 10:10:19 +03:00
Andreea Pavel d45f43c124 Backed out changeset 6fd96d40bdb3 (bug 1400233) at request a=backout r=whimboo 2018-04-06 10:08:55 +03:00
wambui e4f7f97546 Bug 1400233 - Drop ContentWebElement.LegacyIdentifier key from Marionette; r=ato
Remove the legacy key that Marionette uses in addition to the identifier key.

MozReview-Commit-ID: 6IVtLxOJPoS

--HG--
extra : rebase_source : 8c4628d32cdcc7b1b7145b8c7c2660708f3bd20d
2018-03-13 11:56:13 +03:00
Andreas Tolfsen e901dff0cc Bug 1321517 - Propagate exception from server subprocess and re-raise. r=whimboo
When an exception occurs during startup of ServerProxy it is logged
to stdout and the subprocess terminates.  The exception is however not
propagated/communicated to the parent process so it can take action on it.

This patch returns the exception via the BlockingChannel pipe and
re-raises it in the parent process.  This will cause serve.py to
exit if one of the HTTPD servers fails to start.  This fixes the
problem reported in bug 1321517, where the HTTP server lives on when
the HTTPS server fails to start due to a missing certificate or key file.

--HG--
extra : rebase_source : 0ce71952259e10d427fa384f155a1db1d67517ef
2018-03-28 16:06:14 +01:00
Johann Hofmann 4a0b3d1219 Bug 1348223 - Part 4 - Add and update tests for removing site data and cookies in the page info window. r=florian
MozReview-Commit-ID: gAaComSklW

--HG--
extra : rebase_source : 8bc84de30f2168bd29def812f5a2550fb9c0e1a6
2018-03-22 17:29:51 +01:00
Peter Van der Beken 5e6f3328ec Bug 1448850 - Remove nsIMessageListener and nsIMessageListenerManager. r=bz.
--HG--
extra : rebase_source : 2938f6e1cb9078a6d45a8d58db0f6bf70e461b9c
2018-02-16 15:28:31 +01:00
Henrik Skupin d5fa7501a9 Bug 1449862 - [marionette] Check for available port each time before starting binary. r=ato
To prevent race conditions when a formerly started Firefox instance is
still claiming the port of the server socket, the port availability has
to be checked each time before the binary gets started. Otherwise the
client could accidentally connect to the wrong process, and also would
run the remaining tests with it.

MozReview-Commit-ID: JUaHYD2b1Rf

--HG--
extra : rebase_source : 842227b95ab996106f81d86785cc242b6b4cf3ee
2018-03-29 10:01:45 +02:00
Henrik Skupin 8369cbcd06 Bug 1449612 - [marionette] Improve logging when server socket failed to start. r=ato
Raises a better understandable error when the server socket cannot be
created. It includes the port number, and removes the
unhelpful output of the internal error.

MozReview-Commit-ID: AD1leBlWXLR

--HG--
extra : rebase_source : b5386a264ff8d2ddda2b0133298d7e3a9d14320d
2018-03-28 19:17:46 +02:00
Boris Zbarsky 20e0796330 Bug 1447472 part 3. Remove nsIDOMNSEvent. r=qdot
MozReview-Commit-ID: HT1gskFxEZL
2018-03-26 14:53:53 -04:00
Felipe Gomes 28c05e90cc Bug 1448197 - Backout Marionette policy test that should be rewritten. r=backout test-only 2018-03-26 14:11:01 -03:00
Boris Zbarsky de9297b4bf Bug 1448048. Restrict the window.Components shim to non-nightly-only to see whether sites actually use it. r=mccr8
MozReview-Commit-ID: 6W1nEyKGlER
2018-03-23 12:53:48 -04:00
Gurzau Raul f2571e02d0 Backed out changeset 94a8e9c4c345 (bug 1448048) for Robocop failures on Android on a CLOSED TREE 2018-03-23 23:29:02 +02:00
Boris Zbarsky 0327e321d5 Bug 1448048. Restrict the window.Components shim to non-nightly-only to see whether sites actually use it. r=mccr8
MozReview-Commit-ID: 6W1nEyKGlER
2018-03-23 12:53:48 -04:00
arthur.iakab 24af737f4c Merge inbound to mozilla-central. a=merge 2018-03-22 01:46:39 +02:00
Peter Van der Beken f5754d679a Bug 888600 - Move ContentFrameMessageManager to WebIDL. Part 6: Mark some IDL interfaces as non-scriptable. r=bz.
--HG--
extra : rebase_source : 5911f91bd7a63cd3603494e087e3858bd0527500
2018-03-01 20:19:56 +01:00
Henrik Skupin 30775ef148 Bug 1381519 - Find element for (partial) link text has to use rendered content. r=ato
To retrieve links via "link text" or "partial link text" the rendered
content of the element has to be used. This can be the case for CSS
transformations like "uppercase".

MozReview-Commit-ID: fxaHEuWnbf

--HG--
extra : rebase_source : d283275a538662e1f199fd5646997f302c4b8ac7
2017-12-05 13:25:09 +01:00
Coroiu Cristina 6915bab3ba Backed out changeset 5ba7d67fddaa (bug 1381519) for linting failures at builds/worker/checkouts/gecko/testing/marionette/element.js on a CLOSED TREE 2018-03-21 20:40:38 +02:00
Henrik Skupin 524588210f Bug 1381519 - Find element for (partial) link text has to use rendered content. r=ato
To retrieve links via "link text" or "partial link text" the rendered
content of the element has to be used. This can be the case for CSS
transformations like "uppercase".

MozReview-Commit-ID: fxaHEuWnbf

--HG--
extra : rebase_source : 9336a5ede468046e06f065f401a461dde5848a18
2017-12-05 13:25:09 +01:00
Henrik Skupin 33405c5a0c Bug 1430717 - Skip test_cli_arguments.py TestCommandLineArguments.test_startup_timeout. r=whimboo
The test is causing intermittent failures of type "1000s of no output" for
the Mn jobs. It needs to be skipped until at least bug 1433873 has been
fixed.

MozReview-Commit-ID: 5Kpq8wYT1Bt

--HG--
extra : rebase_source : ad9a99edaceb32e27acfc0e71d10a509933fa6d5
2018-03-20 23:03:57 +01:00
Andreas Tolfsen 7f827140bb Bug 1447045 - Increase maximize delta to 22 px. r=maja_zf
Linux window managers and desktop environments can cause the available
surface area of the screen to be shrunk due to UI elements such as
menus.  Window managers can also add additional window decorations
that are outside the control of Firefox.

When X11 forwarding a Firefox window to macOS the XQuartz window
decoration adds 22 px.  This patch increases the delta from 8 px.

MozReview-Commit-ID: 8I6G6cZvAmD

--HG--
extra : rebase_source : fda691e4286d6af815fdf77749c1097c66fee490
2018-03-19 16:35:26 +00:00
Andrew Halberstadt 246d6dddec Bug 1444152 - [test] Fix regression running marionette tests with |mach test|, r=whimboo
There were two issues:
1) The mach command name in resolve.py was wrong.
2) The marionette harness uses deepcopy on the passed in kwargs and sometimes
the 'log' argument that testing/mach_commands.py was passing in can be a class
instance (which can't be deepcopied).

MozReview-Commit-ID: 5gPxuiHs3dY

--HG--
extra : rebase_source : 63bc9c84fdcb540862f1dcbc2654bf5729e0dec8
2018-03-13 09:49:09 -04:00
Boris Zbarsky 837dc7eaaa Bug 1446711 part 8. Get rid of nsIDOMMouseEvent. r=qdot
MozReview-Commit-ID: 2FK1MA4LGZj
2018-03-20 00:16:07 -04:00
Boris Zbarsky 89ea512161 Bug 1446711 part 7. Switch the nsIDOMMouseEvent::MOZ_SOURCE_* constants over to MouseEventBinding. r=qdot
We can't include MouseEventBinding.h in MouseEvents.h because that produces
this include loop:

MouseEventBinding.h -> UIEventBinding.h ->
nsGlobalWindow.h -> nsGlobalWindowInner.h -> nsRefreshDriver.h ->
AnimationEventDispatcher.h -> AnimationComparator.h -> Animation.h ->
EffectCompositor.h -> PseudoElementHashEntry.h -> Element.h ->
PointerEventHandler.h -> MouseEvents.h -> MouseEventBinding.h

MozReview-Commit-ID: 6FNksGil7uD
2018-03-20 00:16:06 -04:00
Yuki Hiroshi 6f6e95b2d4 Bug 1440573 - Policy: Disable safe mode. r=jimm,felipe
This policy disables the safe-mode UI entry points. In addition, only on Windows when using GPO, it also disables entering Safe Mode by holding down the Shift Key
2018-03-15 23:06:22 -03:00
Brindusan Cristian ed15f7d5a4 Backed out changeset 83dffebb1536 (bug 1440573) for bc failures on browser_policy_disable_safemode.js CLOSED TREE 2018-03-16 05:15:39 +02:00
Yuki Hiroshi 22e8dbd8fb Bug 1440573 - Policy: Disable safe mode. r=jimm,felipe
This policy disables the safe-mode UI entry points. In addition, only on Windows when using GPO, it also disables entering Safe Mode by holding down the Shift Key
2018-03-15 23:06:22 -03:00