Commit graph

429 commits

Author SHA1 Message Date
Andreas Tolfsen
091ef4438c bug 1546303: webdriver: add WPT tests for properties in evaluated scripts; r=whimboo
This adds a basic set of tests for interacting with various kinds
of DOM properties from the WebDriver commands Execute Script and
Execute Async Script.

Differential Revision: https://phabricator.services.mozilla.com/D28453

--HG--
extra : moz-landing-system : lando
2019-04-23 14:09:43 +00:00
Andreas Tolfsen
cf526c8480 bug 1546319: webdriver: add Get Element Property tests for mutated web content; r=automatedtester
There are approximately zero coverage for properties modified or set
by web content and through script evaluation.  The only succcess
path test for Get Element Property is test_element, but it checks
an attribute already present in the prototype of the HTMLInputElement.

This patch adds tests where the property is defined through web
content.  This uncovers a defect in Firefox, where Get Element
Property seemingly operates on the initial value of the attribute.

Differential Revision: https://phabricator.services.mozilla.com/D28463

--HG--
extra : moz-landing-system : lando
2019-04-23 13:38:53 +00:00
Andreas Tolfsen
74f864dd78 bug 1546319: webdriver: sanitise get_element_property/get.py; r=automatedtester
Nothing remarkable in this patch.

Differential Revision: https://phabricator.services.mozilla.com/D28462

--HG--
extra : moz-landing-system : lando
2019-04-23 13:38:35 +00:00
Ehsan Akhgari
97c75e0827 Bug 1541250 - Change wdspec tests to not rely on cookie max-age lifetimes a year from now; r=ato
24 hours expiry time should be sufficient for the testing purposes here.

Differential Revision: https://phabricator.services.mozilla.com/D26326

--HG--
extra : moz-landing-system : lando
2019-04-05 15:36:37 +00:00
Christian Bromann
b19fbd8064 Bug 1507507 [wpt PR 14074] - Add test for response headers, a=testonly
Automatic update from web-platform-tests
Add test for response headers (#14074)

--

wpt-commits: d4320a35702c80c3625935749ab15619b209f2a0
wpt-pr: 14074
2019-04-01 14:42:19 +01:00
Henrik Skupin
944e06dfff Bug 1495513 - [wdspec] Add tests for file protocol. r=ato
Differential Revision: https://phabricator.services.mozilla.com/D20488

--HG--
extra : moz-landing-system : lando
2019-02-20 18:40:04 +00:00
Henrik Skupin
91bc440ca6 Bug 1528463 - [wdspec] Run each "Send Alert Text" in its own tab. r=jgraham
To prevent possible rate limits by the browser when running the
tests in verify mode, each test should run in its own tab.

Differential Revision: https://phabricator.services.mozilla.com/D20312

--HG--
extra : moz-landing-system : lando
2019-02-19 15:37:38 +00:00
Henrik Skupin
7753f55f6b Bug 1502360 - [marionette] "Send Alert Text" has to use the text field's value property. r=ato
Depends on D20002

Differential Revision: https://phabricator.services.mozilla.com/D20004

--HG--
extra : moz-landing-system : lando
2019-02-16 00:03:21 +00:00
Henrik Skupin
ba5b2fb08e Bug 1502360 - [wdspec] Add basic HTTP auth test for "Send Alert Text". r=ato
Depends on D19998

Differential Revision: https://phabricator.services.mozilla.com/D19999

--HG--
extra : moz-landing-system : lando
2019-02-16 07:12:13 +00:00
Daniel Varga
30780abeeb Merge mozilla-inbound to mozilla-central. a=merge 2019-02-15 03:41:17 +02:00
Henrik Skupin
72f690a447 Bug 1398095 - [wdspec] Add promise tests for Execute Async Script command. r=ato
Depends on D19755

Differential Revision: https://phabricator.services.mozilla.com/D19757

--HG--
extra : moz-landing-system : lando
2019-02-14 13:39:55 +00:00
Henrik Skupin
39806892a5 Bug 1398095 - [marionette] Use promises internally for Execute (Async) Script. r=ato
Depends on D19753

Differential Revision: https://phabricator.services.mozilla.com/D19755

--HG--
extra : moz-landing-system : lando
2019-02-14 13:39:19 +00:00
Henrik Skupin
93fa5a2367 Bug 1398095 - [wdspec] Use "script timeout" instead of "timeout error" for promise tests. r=ato
Differential Revision: https://phabricator.services.mozilla.com/D19751

--HG--
extra : moz-landing-system : lando
2019-02-14 13:37:58 +00:00
John Chen
a6c3acff12 Bug 1523562 [wpt PR 15055] - Fix code associated with several keys, a=testonly
Automatic update from web-platform-tests
webdriver: fix codes associated with several keys (#15055)

--

wpt-commits: da7bb34afb94f1076855343e0b9a1c8037255d53
wpt-pr: 15055
2019-02-07 21:51:10 +00:00
jimevans
2d953e32b5 Bug 1523562 [wpt PR 15043] - Updating WebDriver new window command tests to switch window, a=testonly
Automatic update from web-platform-tests
Updating WebDriver new window command tests to switch window (#15043)

As originally implemented, the tests set the `handle` property of
the session instead of the `window_handle` property. So they don't
switch to the new window context before checking the
url, opener, and name. This commit fixes it.
--

wpt-commits: 363fd4ea3dd3f3ee5fde4f56bf26a3ad690b3b78
wpt-pr: 15043
2019-02-07 21:51:05 +00:00
John Chen
4f45204206 Bug 1516570 [wpt PR 14678] - Fix key code for NUMPAD4 and NUMPAD5, a=testonly
Automatic update from web-platform-tests
webdriver: fix key code for NUMPAD4 and NUMPAD5 (#14678)

--

wpt-commits: 6f5ee87390438c901d05e1ee39be634fc186aa01
wpt-pr: 14678
2019-02-07 21:49:37 +00:00
jimevans
6760851fd6 Bug 1526555 [wpt PR 15204] - Enabling older browsers values for KeyboardEvent.key in WebDriver tests, a=testonly
Automatic update from web-platform-tests
webdriver: enable older browsers values for KeyboardEvent.key (#15204)

When propagating keyboard events, older browsers use different strings
for the "key" property of the KeyboardEvent object. This commit enables
the ability of the WebDriver tests for keyboard events to validate the
comparison to these older values in addition to the values used by
modern browsers. See the footnotes in the sections of the following:

https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent/key/Key_Values

--

wpt-commits: b879d5c7d8103cdb6948c2a4d8d8b31f845dae7b
wpt-pr: 15204
2019-02-14 11:38:53 +00:00
jimevans
b909fc42e1 Bug 1526541 [wpt PR 15208] - Replicating "Alt" key workaround for IE WebDriver tests, a=testonly
Automatic update from web-platform-tests
webdriver: replicate "Alt" key workaround for IE WebDriver tests (#15208)

When the Alt key is pressed on Windows, it activates the menu bar for
the focused application. This means that subsequent operations must
first dismiss the menu before being able to carry on. This commit
for Internet Explorer duplicates the workaround for Alt keys from
the test_special_key_sends_keydown subtest in key_events.py to the
test_modifier_key_sends_correct_events subtest.

--

wpt-commits: 9366e48c23a041b398b3345ba8bce6fc66a934ff
wpt-pr: 15208
2019-02-14 11:38:51 +00:00
Henrik Skupin
7417b70f91 Bug 1507283 - [wdspec] Remove invalid set timeout test "test_key_invalid". r=ato
Depends on D17634

Differential Revision: https://phabricator.services.mozilla.com/D17675

--HG--
extra : moz-landing-system : lando
2019-01-25 20:06:50 +00:00
Henrik Skupin
0c6ab3dd41 Bug 1509513 - [wdspec] Add tests for "New Window" command. r=ato
Depends on D16505

Differential Revision: https://phabricator.services.mozilla.com/D16506

--HG--
extra : moz-landing-system : lando
2019-01-16 13:10:51 +00:00
Henrik Skupin
a574b9e9e4 Bug 1478358 - [wdspec] Enhance tests for the "Set Window Rect" command. r=ato
Depends on D16340

Differential Revision: https://phabricator.services.mozilla.com/D16342

--HG--
extra : moz-landing-system : lando
2019-01-11 23:25:01 +00:00
Henrik Skupin
fe47f85c0b Bug 1478358 - [wdspec] Enforce a default window position for each session. r=ato
To have the same pre-conditions for all wdspec tests, the session fixture
has to set a default window position.

Depends on D16338

Differential Revision: https://phabricator.services.mozilla.com/D16340

--HG--
extra : moz-landing-system : lando
2019-01-14 06:31:05 +00:00
shindli
e196689816 Merge inbound to mozilla-central. a=merge 2019-01-09 23:42:10 +02:00
Henrik Skupin
9f79ca4861 Bug 1517196 - [wdspec] Add tests for "Switch To Frame" command. r=ato
Depends on D15953

Differential Revision: https://phabricator.services.mozilla.com/D15954

--HG--
extra : moz-landing-system : lando
2019-01-09 15:53:11 +00:00
Kristian Klausen
b21f9d63a7 bug 1385706: marionette: fix WebDriver:TakeScreenshot to use viewport bounds; r=ato
The WebDriver:TakeScreenshot command relied on the document element's
clientWidth/clientHeight, but should according to the WebDriver
specification use the viewport's dimensions.

Thanks-to: JinaJita <jitajina@gmail.com>
2019-01-09 15:06:50 +00:00
Noemi Erli
94a824b783 Backed out changeset 76be2a9fde9e (bug 1385706) per developer's request CLOSED TREE 2019-01-09 17:00:32 +02:00
Andreas Tolfsen
e490d97127 bug 1385706: marionette: fix WebDriver:TakeScreenshot to use viewport bounds; r=ato
The WebDriver:TakeScreenshot command relied on the document element's
clientWidth/clientHeight, but should according to the WebDriver
specification use the viewport's dimensions.

Thanks-to: JinaJita <jitajina@gmail.com>
2019-01-09 14:49:38 +00:00
reimu
d8cfc514e4 Bug 1128997 - Support indefinite script timeout r=ato
Differential Revision: https://phabricator.services.mozilla.com/D13181

--HG--
extra : moz-landing-system : lando
2019-01-06 23:04:41 +00:00
Andreas Tolfsen
c75b1129c5 bug 1496489: webdriver: re-enable test_maximize_when_resized_to_max_size; r=whimboo
Marionette recently had changes made to its window maximisation algorithm
that lets us re-enable this test.  It tests that session.window.maximize()
does not hang when the window is already maximised.

Differential Revision: https://phabricator.services.mozilla.com/D15582

--HG--
extra : moz-landing-system : lando
2019-01-03 14:10:48 +00:00
Olli Pettay
fd23b8338a Bug 1498383 - clear.py relies on old Gecko's <button> hit testing, r=ato
--HG--
extra : rebase_source : 6ab352c153d5ef45acadd83c94b4e35d371ea90b
2018-10-12 14:21:41 +03:00
jugglinmike
82eb93515e Bug 1477466 [wpt PR 12118] - [permissions] Add tests for "Set Permission", a=testonly
Automatic update from web-platform-tests[permissions] Add tests for "Set Permission" (#12118)

https://w3c.github.io/permissions/#automation
--

wpt-commits: 265b7a171ff52dff31a5cb0646ae55b5799f6be5
wpt-pr: 12118
2018-12-12 10:50:06 +00:00
jimevans
da86a2fcf1 Bug 1508398 [wpt PR 14130] - Updating WebDriver scroll into view tests to support older user agents, a=testonly
Automatic update from web-platform-testswebdriver: update scroll into view tests to support older user agents (#14130)

Removing the use of ES6 constructs (fat-arrow and object shortcut
syntax) as well as adding use of alternatives for user agents that
do not support window.scrollX and window.scrollY.
--

wpt-commits: fcef20974685c994c830a23eae88906449fe93f7
wpt-pr: 14130
2018-11-23 18:36:51 +00:00
jimevans
5dc8403338 Bug 1506409 [wpt PR 14015] - Remove ES6 object matching shorthand notation from WebDriver tests, a=testonly
Automatic update from web-platform-testsRemove ES6 object matching shorthand notation from WebDriver tests (#14015)

This change is to allow older user agents that do not support ES6
constructs to run the WebDriver tests.
--

wpt-commits: fc1a5b73230225faf32bfb85f3928ce154211b0a
wpt-pr: 14015
2018-11-14 13:38:23 +00:00
Christian Bromann
e7df8c85ca Bug 1503238 [wpt PR 13781] - [webdriver]: add checks for execute_script tests recognising promises, a=testonly
Automatic update from web-platform-testswebdriver add promise tests for execute_script (#13781)

--

wpt-commits: cb1b82ae9314fade8ea8796aafd9c2fc409c3b4a
wpt-pr: 13781
2018-11-14 13:37:47 +00:00
jimevans
6e34062f5b Bug 1503450 [wpt PR 13799] - Remove ES6 construct from WebDriver element click center point tests, a=testonly
Automatic update from web-platform-testswebdriver: remove ES6 construct from in-view center point tests (#13799)

Older user agents (read: "Internet Explorer") do not support the
ES6 "fat arrow" construct. Changing the test event handler to the
older function-based syntax.
--

wpt-commits: b704e37ec97fe90b3a3d59c10f78c21907b5b576
wpt-pr: 13799
2018-11-10 09:02:36 +00:00
Andreas Tolfsen
9ca9639faa bug 1505806: webdriver: throttle window rect calls; r=whimboo
By throttling the Get Window Rect calls we avoid the buffer filling
up on Windows, and avoid errors such as: [Errno 10055] An operation
on a socket could not be performed because the system lacked
sufficient buffer space or because a queue was full

Differential Revision: https://phabricator.services.mozilla.com/D11410

--HG--
extra : moz-landing-system : lando
2018-11-09 10:54:16 +00:00
Andreas Tolfsen
5e151181ca bug 1492499: webdriver: add stress tests for window manipulation; r=automatedtester
Depends on D8410

Differential Revision: https://phabricator.services.mozilla.com/D8411

--HG--
extra : moz-landing-system : lando
2018-11-08 13:11:06 +00:00
Andreas Tolfsen
51c24a94ae bug 1492499: webdriver: take 22px window border into account on maximizing; r=automatedtester,whimboo
On some systems and window managers, such as macOS and when X11
forwarding an application across systems, there exists a 22px
window border that we cannot detect or do anything about.  As this
test is to verify that the width/height changed beyond 800x600,
this assertion change should make the tests pass on more configurations.

Depends on D8409

Differential Revision: https://phabricator.services.mozilla.com/D8410

--HG--
extra : moz-landing-system : lando
2018-11-08 13:11:04 +00:00
Andreas Tolfsen
9ed9bc597c bug 1504485: webdriver: reduce amount of styling in element click interactability test; r=whimboo
The amount of CSS styling in this test is too damn high.

Differential Revision: https://phabricator.services.mozilla.com/D10823

--HG--
extra : moz-landing-system : lando
2018-11-07 13:04:43 +00:00
Andreas Tolfsen
79ae7408d8 bug 1505142: webdriver: replace iterator with literal list; r=whimboo
The iterator returned by reversed() can apparently return None in
some configurations.  WPT treats this as an in-test skip and errors
the test.  To avoid this configuration-specific problem we use a
literal list.

Differential Revision: https://phabricator.services.mozilla.com/D11159

--HG--
extra : moz-landing-system : lando
2018-11-07 12:49:33 +00:00
Andreas Tolfsen
57c0eb73e2 bug 1493115: webdriver: test scroll behaviour on partially visible elements; r=whimboo
Partially visible elements should according to WebDriver not be
scrolled into view.  Drivers first run the in-view centre point
algorithm to determine if any portion of the targetted element is
in view, and if it is not, the element is scrolled into view.

As little as a 1 CSS pixel is sufficient for the element to deemed
in view.  Implementations have had problems with deeming elements
out of view when a single pixel border has in fact been in view due
to faulty rounding of the target point, which is why we test a range
from 10 to 1 pixels.

Depends on D10821

Differential Revision: https://phabricator.services.mozilla.com/D10822

--HG--
extra : moz-landing-system : lando
2018-11-06 11:33:33 +00:00
Andreas Tolfsen
fc7c71b1a4 bug 1493115: webdriver: move center_point into helpers; r=whimboo
Differential Revision: https://phabricator.services.mozilla.com/D10821

--HG--
extra : moz-landing-system : lando
2018-11-05 10:08:53 +00:00
Andreas Tolfsen
c39bd2c6dd bug 1504486: webdriver: add test of hidden element for element send keys; r=whimboo
Differential Revision: https://phabricator.services.mozilla.com/D10825

--HG--
extra : moz-landing-system : lando
2018-11-05 10:21:44 +00:00
Andreas Tolfsen
72bb3f4e6c bug 1504488: webdriver: add basic interactability tests for element click; r=whimboo
These tests are largely ported from element_send_keys/interactability.py.

Differential Revision: https://phabricator.services.mozilla.com/D10826

--HG--
extra : moz-landing-system : lando
2018-11-05 20:32:19 +00:00
Henrik Skupin
f98d52bad6 Bug 1503804 - [wdspec] Assert for expected screenshot dimensions. r=ato
Depends on D10627

Differential Revision: https://phabricator.services.mozilla.com/D10628

--HG--
rename : testing/web-platform/mozilla/tests/webdriver/take_full_screenshot.py => testing/web-platform/mozilla/tests/webdriver/take_full_screenshot/screenshot.py
extra : moz-landing-system : lando
2018-11-05 16:42:54 +00:00
Henrik Skupin
e4f809e38c Bug 1503804 - [wdspec] Use shared assert_png() method in screenshot tests. r=ato
Depends on D10626

Differential Revision: https://phabricator.services.mozilla.com/D10627

--HG--
extra : moz-landing-system : lando
2018-11-05 16:42:26 +00:00
Andreas Tolfsen
188b9d80bf bug 1502864: webdriver: sort invalid_extensions list; r=jgraham
Depends on D10271

Depends on D10271

Differential Revision: https://phabricator.services.mozilla.com/D10272

--HG--
extra : moz-landing-system : lando
2018-11-03 16:32:36 +00:00
Andreas Tolfsen
678d20403f bug 1502864: webdriver: add strictFileInteractability capability tests; r=jgraham
The new strictFileInteractabilityTests capability takes a boolean and
can unconditionally be set to both true and false.  It is permitted
to be undefined.

Depends on D10270

Depends on D10270

Differential Revision: https://phabricator.services.mozilla.com/D10271

--HG--
extra : moz-landing-system : lando
2018-11-03 16:32:38 +00:00
Andreas Tolfsen
a3c6652e2c bug 1502864: webdriver: add tests for hidden <input type=file>; r=jgraham,whimboo
The WebDriver standard changed
in https://github.com/w3c/webdriver/pull/1325 to align with
chromedriver's behaviour of permitting interaction with hidden
<input type=file> elements.

DOM elements can be hidden, i.e. not rendered, in two ways: through
applying the "hidden" DOM attribute or by setting the "display:
none" CSS style.

Depends on D10269

Depends on D10269

Differential Revision: https://phabricator.services.mozilla.com/D10270

--HG--
extra : moz-landing-system : lando
2018-11-03 16:32:40 +00:00
Andreas Tolfsen
717cf012c0 bug 1502864: webdriver: add tests for keyboard interactability for <input type=file>; r=jgraham
Normally all interactability tests are centralised in interactability.py,
but the WebDriver standard recently changed to apply a special
set of interactability checks specifically for <input type=file>.
These tests ensure the special code paths are invoked for form controls.

Differential Revision: https://phabricator.services.mozilla.com/D10269

--HG--
extra : moz-landing-system : lando
2018-11-03 16:32:42 +00:00