Update web-platform-tests to revision 6c2e8131efc198de635c2c7ee32bc6b76fd8a0b7

This commit is contained in:
WPT Sync Bot 2021-01-11 08:20:38 +00:00
parent 8d0e687207
commit 0ea03d814a
57 changed files with 414 additions and 192 deletions

View file

@ -1,5 +0,0 @@
[url-charset.window.html]
expected: TIMEOUT
[Blob charset should override any auto-detected charset.]
expected: TIMEOUT

View file

@ -1,4 +0,0 @@
[hit-test-floats-002.html]
[Hit test float]
expected: FAIL

View file

@ -0,0 +1,4 @@
[hit-test-floats-003.html]
[Miss float below something else]
expected: FAIL

View file

@ -0,0 +1,4 @@
[hit-test-floats-004.html]
[Miss float below something else]
expected: FAIL

View file

@ -0,0 +1,4 @@
[CaretPosition-001.html]
[Element at (400, 100)]
expected: FAIL

View file

@ -17,6 +17,3 @@
[test the top of layer]
expected: FAIL
[test some point of the element: top left corner]
expected: FAIL

View file

@ -312,15 +312,18 @@
[<iframe>: separate response Content-Type: text/html */*;charset=gbk]
expected: FAIL
[<iframe>: combined response Content-Type: */* text/html]
expected: FAIL
[<iframe>: separate response Content-Type: text/html;" \\" text/plain]
expected: FAIL
[<iframe>: combined response Content-Type: text/html;charset=gbk text/plain text/html]
expected: FAIL
[<iframe>: combined response Content-Type: text/html */*;charset=gbk]
expected: FAIL
[<iframe>: combined response Content-Type: text/html;" text/plain]
expected: FAIL
[<iframe>: separate response Content-Type: text/html;" text/plain]
expected: FAIL
[<iframe>: separate response Content-Type: text/html */*]
expected: FAIL
[<iframe>: separate response Content-Type: text/plain */*;charset=gbk]
expected: FAIL

View file

@ -56,3 +56,6 @@
[separate text/javascript;charset=windows-1252 error text/javascript]
expected: FAIL
[separate text/javascript x/x]
expected: FAIL

View file

@ -0,0 +1,4 @@
[traverse_the_history_4.html]
[Multiple history traversals, last would be aborted]
expected: FAIL

View file

@ -1,5 +1,4 @@
[creating_browsing_context_test_01.html]
expected: TIMEOUT
[first argument: absolute url]
expected: TIMEOUT
expected: FAIL

View file

@ -1,15 +1,16 @@
[supported-elements.html]
expected: TIMEOUT
[Contenteditable element should support autofocus]
expected: FAIL
[Host element with delegatesFocus including no focusable descendants should be skipped]
expected: FAIL
expected: TIMEOUT
[Element with tabindex should support autofocus]
expected: FAIL
[Area element should support autofocus]
expected: FAIL
expected: NOTRUN
[Host element with delegatesFocus should support autofocus]
expected: FAIL

View file

@ -171,3 +171,6 @@
[XHTML img usemap="#hash-id"]
expected: FAIL
[HTML (standards) IMG usemap="no-hash-name"]
expected: FAIL

View file

@ -1,4 +1,5 @@
[iframe_sandbox_popups_nonescaping-3.html]
expected: TIMEOUT
[Check that popups from a sandboxed iframe do not escape the sandbox]
expected: FAIL
expected: NOTRUN

View file

@ -0,0 +1,4 @@
[form-double-submit-3.html]
[<button> should have the same double-submit protection as <input type=submit>]
expected: FAIL

View file

@ -11,21 +11,12 @@
[input type url: select() a second time (must not fire select)]
expected: FAIL
[input type password: setRangeText() a second time (must not fire select)]
expected: FAIL
[input type text: selectionStart out of range a second time (must not fire select)]
expected: FAIL
[input type password: setSelectionRange out of range a second time (must not fire select)]
expected: FAIL
[input type url: selectionEnd out of range a second time (must not fire select)]
expected: FAIL
[input type password: selectionEnd a second time (must not fire select)]
expected: FAIL
[textarea: selectionStart out of range a second time (must not fire select)]
expected: FAIL
@ -35,51 +26,54 @@
[input type password: selectionStart a second time (must not fire select)]
expected: FAIL
[input type text: selectionEnd a second time (must not fire select)]
expected: FAIL
[input type tel: setRangeText() a second time (must not fire select)]
expected: FAIL
[textarea: selectionDirection a second time (must not fire select)]
expected: FAIL
[input type url: selectionEnd a second time (must not fire select)]
expected: FAIL
[input type search: setSelectionRange out of range a second time (must not fire select)]
expected: FAIL
[textarea: setSelectionRange() a second time (must not fire select)]
expected: FAIL
[input type text: setSelectionRange() a second time (must not fire select)]
expected: FAIL
[input type url: selectionStart out of range a second time (must not fire select)]
expected: FAIL
[input type search: setSelectionRange() a second time (must not fire select)]
expected: FAIL
[input type search: selectionStart out of range a second time (must not fire select)]
expected: FAIL
[input type text: selectionEnd out of range a second time (must not fire select)]
expected: FAIL
[input type search: selectionEnd a second time (must not fire select)]
expected: FAIL
[input type search: selectionEnd out of range a second time (must not fire select)]
expected: FAIL
[input type url: setRangeText() a second time (must not fire select)]
expected: FAIL
[input type tel: selectionStart a second time (must not fire select)]
expected: FAIL
[input type search: selectionStart a second time (must not fire select)]
expected: FAIL
[input type password: select() a second time (must not fire select)]
expected: FAIL
[input type tel: selectionEnd out of range a second time (must not fire select)]
expected: FAIL
[input type password: selectionEnd out of range a second time (must not fire select)]
expected: FAIL
[input type password: setSelectionRange() a second time (must not fire select)]
expected: FAIL
[input type text: setSelectionRange out of range a second time (must not fire select)]
expected: FAIL
[input type tel: selectionStart out of range a second time (must not fire select)]
expected: FAIL
[input type tel: setSelectionRange() a second time (must not fire select)]
expected: FAIL
[input type url: selectionDirection a second time (must not fire select)]
expected: FAIL
[input type tel: selectionEnd a second time (must not fire select)]
expected: FAIL
[input type text: selectionStart a second time (must not fire select)]
expected: FAIL
[input type tel: select() a second time (must not fire select)]
expected: FAIL
[input type search: setRangeText() a second time (must not fire select)]
expected: FAIL
[textarea: selectionEnd out of range a second time (must not fire select)]
expected: FAIL

View file

@ -1,14 +1,13 @@
[htmlanchorelement_noopener.html]
expected: TIMEOUT
[Check that targeting of rel=noopener with a given name reuses an existing window with that name]
expected: FAIL
[Check that rel=noopener with target=_top does a normal load]
expected: NOTRUN
expected: FAIL
[Check that rel=noopener with target=_parent does a normal load]
expected: NOTRUN
expected: FAIL
[Check that rel=noopener with target=_self does a normal load]
expected: NOTRUN
expected: FAIL

View file

@ -1,4 +0,0 @@
[module-delayed.html]
[async document.write in a module]
expected: FAIL

View file

@ -1,5 +1,4 @@
[realtimeanalyser-fft-scaling.html]
expected: TIMEOUT
[X 2048-point FFT peak position is not equal to 64. Got 0.]
expected: FAIL

View file

@ -515,3 +515,9 @@
[X Stitched sine-wave buffers at sample rate 43800 does not equal [0,0.06264832615852356,0.12505052983760834,0.18696144223213196,0.24813786149024963,0.308339387178421,0.36732959747314453,0.4248766601085663,0.480754554271698,0.5347436666488647,0.5866320133209229,0.6362156271934509,0.6832997798919678,0.7276994585990906,0.7692402601242065,0.8077589869499207...\] with an element-wise tolerance of {"absoluteThreshold":0.0038986,"relativeThreshold":0}.\n\tIndex\tActual\t\t\tExpected\t\tAbsError\t\tRelError\t\tTest threshold\n\t[28696\]\t9.0254590000000000e+6\t9.3139332532882690e-1\t9.0254580686066747e+6\t9.6902756581600495e+6\t3.8985999999999999e-3\n\t[28697\]\t7.0477002859115601e-1\t9.0675884485244751e-1\t2.0198881626129150e-1\t2.2275913536212616e-1\t3.8985999999999999e-3\n\tMax AbsError of 9.0254580686066747e+6 at index of 28696.\n\tMax RelError of 9.6902756581600495e+6 at index of 28696.\n]
expected: FAIL
[X SNR (-384.65975636989594 dB) is not greater than or equal to 65.737. Got -384.65975636989594.]
expected: FAIL
[X Stitched sine-wave buffers at sample rate 43800 does not equal [0,0.06264832615852356,0.12505052983760834,0.18696144223213196,0.24813786149024963,0.308339387178421,0.36732959747314453,0.4248766601085663,0.480754554271698,0.5347436666488647,0.5866320133209229,0.6362156271934509,0.6832997798919678,0.7276994585990906,0.7692402601242065,0.8077589869499207...\] with an element-wise tolerance of {"absoluteThreshold":0.0038986,"relativeThreshold":0}.\n\tIndex\tActual\t\t\tExpected\t\tAbsError\t\tRelError\t\tTest threshold\n\t[28696\]\t-2.5391719726329690e+21\t9.3139332532882690e-1\t2.5391719726329690e+21\t2.7262080407721607e+21\t3.8985999999999999e-3\n\t[28697\]\t7.0477002859115601e-1\t9.0675884485244751e-1\t2.0198881626129150e-1\t2.2275913536212616e-1\t3.8985999999999999e-3\n\tMax AbsError of 2.5391719726329690e+21 at index of 28696.\n\tMax RelError of 2.7262080407721607e+21 at index of 28696.\n]
expected: FAIL

View file

@ -1,4 +1,5 @@
[audiocontext-not-fully-active.html]
expected: TIMEOUT
[frame in navigated remote-site frame]
expected: FAIL

View file

@ -26,3 +26,6 @@
[test_no_browsing_context_when_already_top_level]
expected: ERROR
[test_frame_id_null]
expected: FAIL

View file

@ -14,3 +14,6 @@
[test_no_browsing_context_when_already_top_level]
expected: ERROR
[test_switch_from_iframe]
expected: FAIL

View file

@ -1,5 +0,0 @@
[018.html]
expected: TIMEOUT
[origin of the script that invoked the method, javascript:]
expected: TIMEOUT

View file

@ -0,0 +1,5 @@
[017.html]
expected: TIMEOUT
[origin of the script that invoked the method, about:blank]
expected: TIMEOUT

View file

@ -1,5 +0,0 @@
[018.html]
expected: TIMEOUT
[origin of the script that invoked the method, javascript:]
expected: TIMEOUT

View file

@ -1,5 +1,4 @@
[import-in-moduleworker.html]
expected: ERROR
[Base URL in module dedicated workers: import]
expected: FAIL

View file

@ -1,5 +0,0 @@
[url-charset.window.html]
expected: TIMEOUT
[Blob charset should override any auto-detected charset.]
expected: TIMEOUT

View file

@ -489517,7 +489517,7 @@
]
],
"radio.html": [
"7dcc9a14a8980898917d8d771041bd691e99785f",
"7f183f8367db079cd3b8e6b7a0dc741e874c4d0f",
[
null,
{}
@ -528226,6 +528226,15 @@
]
],
"textcontrols": {
"focus.html": [
"8c2e0b55914e765bb8b56154aa6638dd0d9f863f",
[
null,
{
"testdriver": true
}
]
],
"selectionchange.tentative.html": [
"adec8b31f3e096eb28ae0246164d637da10bd5ee",
[
@ -590132,7 +590141,7 @@
]
],
"switch.py": [
"07994bed34931940c15aa4f722809c809fd6d20c",
"df7e5b73af419ab464b3a787eee514575af70c37",
[
null,
{}
@ -590155,7 +590164,7 @@
},
"switch_to_parent_frame": {
"switch.py": [
"e05e11953c971b0d45bf24b899d5f0342f5ea305",
"9c6db8d2cd61d6e92f45ac1843dbe0f43f69af76",
[
null,
{}

View file

@ -1,4 +0,0 @@
[hit-test-floats-002.html]
[Hit test float]
expected: FAIL

View file

@ -0,0 +1,4 @@
[hit-test-floats-003.html]
[Miss float below something else]
expected: FAIL

View file

@ -0,0 +1,4 @@
[hit-test-floats-004.html]
[Miss float below something else]
expected: FAIL

View file

@ -0,0 +1,4 @@
[CaretPosition-001.html]
[Element at (400, 100)]
expected: FAIL

View file

@ -21,6 +21,3 @@
[test the top of layer]
expected: FAIL
[test some point of the element: top left corner]
expected: FAIL

View file

@ -312,15 +312,18 @@
[<iframe>: separate response Content-Type: text/html */*;charset=gbk]
expected: FAIL
[<iframe>: combined response Content-Type: */* text/html]
expected: FAIL
[<iframe>: separate response Content-Type: text/html;" \\" text/plain]
expected: FAIL
[<iframe>: combined response Content-Type: text/html;charset=gbk text/plain text/html]
expected: FAIL
[<iframe>: combined response Content-Type: text/html */*;charset=gbk]
expected: FAIL
[<iframe>: combined response Content-Type: text/html;" text/plain]
expected: FAIL
[<iframe>: separate response Content-Type: text/html;" text/plain]
expected: FAIL
[<iframe>: separate response Content-Type: text/html */*]
expected: FAIL
[<iframe>: separate response Content-Type: text/plain */*;charset=gbk]
expected: FAIL

View file

@ -56,3 +56,6 @@
[separate text/javascript;charset=windows-1252 error text/javascript]
expected: FAIL
[separate text/javascript x/x]
expected: FAIL

View file

@ -0,0 +1,4 @@
[traverse_the_history_4.html]
[Multiple history traversals, last would be aborted]
expected: FAIL

View file

@ -1,5 +1,4 @@
[creating_browsing_context_test_01.html]
expected: TIMEOUT
[first argument: absolute url]
expected: TIMEOUT
expected: FAIL

View file

@ -1,4 +1,5 @@
[supported-elements.html]
expected: TIMEOUT
[Contenteditable element should support autofocus]
expected: FAIL
@ -6,10 +7,10 @@
expected: FAIL
[Host element with delegatesFocus including no focusable descendants should be skipped]
expected: FAIL
expected: TIMEOUT
[Area element should support autofocus]
expected: FAIL
expected: NOTRUN
[Host element with delegatesFocus should support autofocus]
expected: FAIL

View file

@ -172,3 +172,6 @@
[XHTML img usemap="http://example.org/#garbage-before-hash-id"]
expected: FAIL
[HTML (standards) IMG usemap="no-hash-name"]
expected: FAIL

View file

@ -1,4 +1,5 @@
[iframe_sandbox_popups_nonescaping-3.html]
expected: TIMEOUT
[Check that popups from a sandboxed iframe do not escape the sandbox]
expected: FAIL
expected: NOTRUN

View file

@ -0,0 +1,4 @@
[form-double-submit-3.html]
[<button> should have the same double-submit protection as <input type=submit>]
expected: FAIL

View file

@ -11,21 +11,12 @@
[input type url: select() a second time (must not fire select)]
expected: FAIL
[input type password: setRangeText() a second time (must not fire select)]
expected: FAIL
[input type text: selectionStart out of range a second time (must not fire select)]
expected: FAIL
[input type password: setSelectionRange out of range a second time (must not fire select)]
expected: FAIL
[input type url: selectionEnd out of range a second time (must not fire select)]
expected: FAIL
[input type password: selectionEnd a second time (must not fire select)]
expected: FAIL
[textarea: selectionStart out of range a second time (must not fire select)]
expected: FAIL
@ -35,51 +26,54 @@
[input type password: selectionStart a second time (must not fire select)]
expected: FAIL
[input type text: selectionEnd a second time (must not fire select)]
expected: FAIL
[input type tel: setRangeText() a second time (must not fire select)]
expected: FAIL
[textarea: selectionDirection a second time (must not fire select)]
expected: FAIL
[input type url: selectionEnd a second time (must not fire select)]
expected: FAIL
[input type search: setSelectionRange out of range a second time (must not fire select)]
expected: FAIL
[textarea: setSelectionRange() a second time (must not fire select)]
expected: FAIL
[input type text: setSelectionRange() a second time (must not fire select)]
expected: FAIL
[input type url: selectionStart out of range a second time (must not fire select)]
expected: FAIL
[input type search: setSelectionRange() a second time (must not fire select)]
expected: FAIL
[input type search: selectionStart out of range a second time (must not fire select)]
expected: FAIL
[input type text: selectionEnd out of range a second time (must not fire select)]
expected: FAIL
[input type search: selectionEnd a second time (must not fire select)]
expected: FAIL
[input type search: selectionEnd out of range a second time (must not fire select)]
expected: FAIL
[input type url: setRangeText() a second time (must not fire select)]
expected: FAIL
[input type tel: selectionStart a second time (must not fire select)]
expected: FAIL
[input type search: selectionStart a second time (must not fire select)]
expected: FAIL
[input type password: select() a second time (must not fire select)]
expected: FAIL
[input type tel: selectionEnd out of range a second time (must not fire select)]
expected: FAIL
[input type password: selectionEnd out of range a second time (must not fire select)]
expected: FAIL
[input type password: setSelectionRange() a second time (must not fire select)]
expected: FAIL
[input type text: setSelectionRange out of range a second time (must not fire select)]
expected: FAIL
[input type tel: selectionStart out of range a second time (must not fire select)]
expected: FAIL
[input type tel: setSelectionRange() a second time (must not fire select)]
expected: FAIL
[input type url: selectionDirection a second time (must not fire select)]
expected: FAIL
[input type tel: selectionEnd a second time (must not fire select)]
expected: FAIL
[input type text: selectionStart a second time (must not fire select)]
expected: FAIL
[input type tel: select() a second time (must not fire select)]
expected: FAIL
[input type search: setRangeText() a second time (must not fire select)]
expected: FAIL
[textarea: selectionEnd out of range a second time (must not fire select)]
expected: FAIL

View file

@ -1,6 +1,5 @@
[htmlanchorelement_noopener.html]
type: testharness
expected: TIMEOUT
[Check that targeting of rel=noopener with a given name ignores an existing window with that name]
expected: NOTRUN
@ -8,11 +7,11 @@
expected: FAIL
[Check that rel=noopener with target=_top does a normal load]
expected: NOTRUN
expected: FAIL
[Check that rel=noopener with target=_parent does a normal load]
expected: NOTRUN
expected: FAIL
[Check that rel=noopener with target=_self does a normal load]
expected: NOTRUN
expected: FAIL

View file

@ -1,4 +0,0 @@
[module-delayed.html]
[async document.write in a module]
expected: FAIL

View file

@ -1,5 +1,4 @@
[realtimeanalyser-fft-scaling.html]
expected: TIMEOUT
[X 2048-point FFT peak position is not equal to 64. Got 0.]
expected: FAIL

View file

@ -743,3 +743,9 @@
[X Stitched sine-wave buffers at sample rate 43800 does not equal [0,0.06264832615852356,0.12505052983760834,0.18696144223213196,0.24813786149024963,0.308339387178421,0.36732959747314453,0.4248766601085663,0.480754554271698,0.5347436666488647,0.5866320133209229,0.6362156271934509,0.6832997798919678,0.7276994585990906,0.7692402601242065,0.8077589869499207...\] with an element-wise tolerance of {"absoluteThreshold":0.0038986,"relativeThreshold":0}.\n\tIndex\tActual\t\t\tExpected\t\tAbsError\t\tRelError\t\tTest threshold\n\t[28696\]\t9.0254590000000000e+6\t9.3139332532882690e-1\t9.0254580686066747e+6\t9.6902756581600495e+6\t3.8985999999999999e-3\n\t[28697\]\t7.0477002859115601e-1\t9.0675884485244751e-1\t2.0198881626129150e-1\t2.2275913536212616e-1\t3.8985999999999999e-3\n\tMax AbsError of 9.0254580686066747e+6 at index of 28696.\n\tMax RelError of 9.6902756581600495e+6 at index of 28696.\n]
expected: FAIL
[X SNR (-384.65975636989594 dB) is not greater than or equal to 65.737. Got -384.65975636989594.]
expected: FAIL
[X Stitched sine-wave buffers at sample rate 43800 does not equal [0,0.06264832615852356,0.12505052983760834,0.18696144223213196,0.24813786149024963,0.308339387178421,0.36732959747314453,0.4248766601085663,0.480754554271698,0.5347436666488647,0.5866320133209229,0.6362156271934509,0.6832997798919678,0.7276994585990906,0.7692402601242065,0.8077589869499207...\] with an element-wise tolerance of {"absoluteThreshold":0.0038986,"relativeThreshold":0}.\n\tIndex\tActual\t\t\tExpected\t\tAbsError\t\tRelError\t\tTest threshold\n\t[28696\]\t-2.5391719726329690e+21\t9.3139332532882690e-1\t2.5391719726329690e+21\t2.7262080407721607e+21\t3.8985999999999999e-3\n\t[28697\]\t7.0477002859115601e-1\t9.0675884485244751e-1\t2.0198881626129150e-1\t2.2275913536212616e-1\t3.8985999999999999e-3\n\tMax AbsError of 2.5391719726329690e+21 at index of 28696.\n\tMax RelError of 2.7262080407721607e+21 at index of 28696.\n]
expected: FAIL

View file

@ -1,4 +1,5 @@
[audiocontext-not-fully-active.html]
expected: TIMEOUT
[frame in navigated remote-site frame]
expected: FAIL

View file

@ -41,3 +41,6 @@
[test_no_browsing_context_when_already_top_level]
expected: ERROR
[test_frame_id_null]
expected: FAIL

View file

@ -14,3 +14,6 @@
[test_no_browsing_context_when_already_top_level]
expected: ERROR
[test_switch_from_iframe]
expected: FAIL

View file

@ -1,5 +0,0 @@
[018.html]
expected: TIMEOUT
[origin of the script that invoked the method, javascript:]
expected: TIMEOUT

View file

@ -0,0 +1,5 @@
[017.html]
expected: TIMEOUT
[origin of the script that invoked the method, about:blank]
expected: TIMEOUT

View file

@ -1,5 +0,0 @@
[018.html]
expected: TIMEOUT
[origin of the script that invoked the method, javascript:]
expected: TIMEOUT

View file

@ -1,5 +1,4 @@
[import-in-moduleworker.html]
expected: ERROR
[Base URL in module dedicated workers: import]
expected: FAIL

View file

@ -204,4 +204,148 @@
radios[0].checked = false;
assert_true(radios[0].validity.valueMissing, 'The first radio should be invalid because of required');
}, 'Radio buttons in an orphan tree should make a group');
test(() => {
const container = document.createElement('div');
container.innerHTML =
'<form>' +
'<input type=radio name=group1 id=radio1 checked>' +
'<input type=radio name=group1 id=radio2>' +
'</form>' +
'<form>' +
'<input type=radio name=group1 id=radio3 checked>' +
'<input type=radio name=group1 id=radio4>' +
'</form>' +
'<input type=radio name=group1 id=radio5 checked>' +
'<input type=radio name=group1 id=radio6>';
const radio1 = container.querySelector('#radio1');
const radio2 = container.querySelector('#radio2');
const radio3 = container.querySelector('#radio3');
const radio4 = container.querySelector('#radio4');
const radio5 = container.querySelector('#radio5');
const radio6 = container.querySelector('#radio6');
// initial conditions
assert_true(radio1.checked, 'radio1 should be checked');
assert_false(radio2.checked, 'radio2 should be unchecked');
assert_true(radio3.checked, 'radio3 should be checked');
assert_false(radio4.checked, 'radio4 should be unchecked');
assert_true(radio5.checked, 'radio5 should be checked');
assert_false(radio6.checked, 'radio6 should be unchecked');
radio2.checked = true;
assert_false(radio1.checked, 'radio1 should be unchecked');
assert_true(radio2.checked, 'radio2 should be checked');
assert_true(radio3.checked, 'radio3 should remain checked');
assert_true(radio5.checked, 'radio5 should remain checked');
radio4.checked = true;
assert_false(radio1.checked, 'radio1 should remain unchecked');
assert_true(radio2.checked, 'radio2 should remain checked');
assert_false(radio3.checked, 'radio3 should be unchecked');
assert_true(radio4.checked, 'radio4 should be checked');
assert_true(radio5.checked, 'radio5 should remain checked');
radio6.checked = true;
assert_false(radio1.checked, 'radio1 should remain unchecked');
assert_true(radio2.checked, 'radio2 should remain checked');
assert_false(radio3.checked, 'radio3 should remain unchecked');
assert_true(radio4.checked, 'radio4 should remain checked');
assert_false(radio5.checked, 'radio5 should be unchecked');
assert_true(radio6.checked, 'radio6 should be checked');
}, "Radio buttons in different groups (because they have different form owners or no form owner) do not affect each other's checkedness");
test(() => {
const container = document.createElement('div');
container.innerHTML =
'<form>' +
'<input type=radio name=group1 id=radio1 checked>' +
'<input type=radio name=group1 id=radio2>' +
'<input type=radio name=group1 id=radio3>' +
'<input type=radio name=group1 id=radio4>' +
'</form>';
const radio1 = container.querySelector('#radio1');
const radio2 = container.querySelector('#radio2');
const radio3 = container.querySelector('#radio3');
const radio4 = container.querySelector('#radio4');
// initial conditions
assert_true(radio1.checked, 'radio1 should be checked');
assert_false(radio2.checked, 'radio2 should be unchecked');
assert_false(radio3.checked, 'radio3 should be unchecked');
assert_false(radio4.checked, 'radio4 should be unchecked');
radio3.remove();
radio4.remove();
radio3.checked = true;
radio4.checked = true;
assert_true(radio1.checked, 'radio1 should remain checked');
assert_false(radio2.checked, 'radio2 should remain unchecked');
assert_true(radio3.checked, 'radio3 should be checked');
assert_true(radio4.checked, 'radio4 should be checked');
}, "Radio buttons in different groups (because they are not in the same tree) do not affect each other's checkedness");
test(() => {
const container = document.createElement('div');
container.innerHTML =
'<form>' +
'<input type=radio name=group1 id=radio1 checked>' +
'<input type=radio name=group1 id=radio2>' +
'<input type=radio name=group2 id=radio3 checked>' +
'<input type=radio name=group2 id=radio4>' +
'<input type=radio name="" id=radio5 checked>' +
'<input type=radio name="" id=radio6>' +
'<input type=radio id=radio7 checked>' +
'<input type=radio id=radio8>' +
'</form>';
const radio1 = container.querySelector('#radio1');
const radio2 = container.querySelector('#radio2');
const radio3 = container.querySelector('#radio3');
const radio4 = container.querySelector('#radio4');
const radio5 = container.querySelector('#radio5');
const radio6 = container.querySelector('#radio6');
const radio7 = container.querySelector('#radio7');
const radio8 = container.querySelector('#radio8');
// initial conditions
assert_true(radio1.checked, 'radio1 should be checked');
assert_false(radio2.checked, 'radio2 should be unchecked');
assert_true(radio3.checked, 'radio3 should be checked');
assert_false(radio4.checked, 'radio4 should be unchecked');
assert_true(radio5.checked, 'radio5 should be checked');
assert_false(radio6.checked, 'radio6 should be unchecked');
assert_true(radio7.checked, 'radio7 should be checked');
assert_false(radio8.checked, 'radio8 should be unchecked');
radio2.checked = true;
assert_false(radio1.checked, 'radio1 should be unchecked');
assert_true(radio2.checked, 'radio2 should be checked');
assert_true(radio3.checked, 'radio3 should remain checked');
assert_false(radio4.checked, 'radio4 should remain unchecked');
assert_true(radio5.checked, 'radio5 should remain checked');
assert_false(radio6.checked, 'radio6 should remain unchecked');
assert_true(radio7.checked, 'radio7 should remain checked');
assert_false(radio8.checked, 'radio8 should remain unchecked');
radio6.checked = true;
assert_false(radio1.checked, 'radio1 should remain unchecked');
assert_true(radio2.checked, 'radio2 should remain checked');
assert_true(radio3.checked, 'radio3 should remain checked');
assert_false(radio4.checked, 'radio4 should remain unchecked');
assert_true(radio5.checked, 'radio5 should remain checked');
assert_true(radio6.checked, 'radio6 should be checked');
assert_true(radio7.checked, 'radio7 should remain checked');
radio8.checked = true;
assert_false(radio1.checked, 'radio1 should remain unchecked');
assert_true(radio2.checked, 'radio2 should remain checked');
assert_true(radio3.checked, 'radio3 should remain checked');
assert_false(radio4.checked, 'radio4 should remain unchecked');
assert_true(radio5.checked, 'radio5 should remain checked');
assert_true(radio6.checked, 'radio6 should remain checked');
assert_true(radio7.checked, 'radio7 should remain checked');
assert_true(radio8.checked, 'radio8 should be checked');
}, "Radio buttons in different groups (because they have different name attribute values, or no name attribute) do not affect each other's checkedness");
</script>

View file

@ -0,0 +1,43 @@
<!DOCTYPE html>
<meta charset="utf-8">
<title>Stop selection extension when focus changes</title>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="/resources/testdriver.js"></script>
<script src="/resources/testdriver-actions.js"></script>
<script src="/resources/testdriver-vendor.js"></script>
<link rel="stylesheet" href="/fonts/ahem.css">
<style>
#p {
font: 16px/1 Ahem;
}
</style>
<p id="p">
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna
aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.
Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint
occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
</p>
<textarea id="textarea">Hello</textarea>
<script>
const selection = getSelection();
const { p, textarea } = document.all;
document.addEventListener("selectionchange", ev => {
if (p.contains(selection.focusNode)) {
textarea.focus();
}
});
promise_test(async () => {
await new test_driver.Actions()
.pointerMove(5, 5, {origin: p})
.pointerDown()
.pointerMove(50, 50)
.pointerUp()
.send();
assert_equals(selection.focusNode, document.body);
assert_equals(selection.focusOffset, 2);
assert_equals(selection.anchorNode, document.body);
assert_equals(selection.focusOffset, 2);
}, "focus() should cancel selection extension by pointer device");
</script>

View file

@ -2,7 +2,7 @@ import pytest
import webdriver.protocol as protocol
from webdriver import StaleElementReferenceException
from webdriver import NoSuchElementException
from webdriver.transport import Response
from tests.support.asserts import assert_error, assert_same_element, assert_success
@ -90,9 +90,9 @@ def test_frame_id_null(session, inline, iframe):
response = switch_to_frame(session, None)
assert_success(response)
with pytest.raises(StaleElementReferenceException):
with pytest.raises(NoSuchElementException):
element2.text
with pytest.raises(StaleElementReferenceException):
with pytest.raises(NoSuchElementException):
element1.text
frame = session.find.css("iframe", all=False)

View file

@ -1,6 +1,6 @@
import pytest
from webdriver import StaleElementReferenceException
from webdriver import NoSuchElementException
from tests.support.asserts import assert_error, assert_success
@ -66,13 +66,13 @@ def test_switch_from_iframe(session, inline, iframe):
session.url = inline(iframe("<p>foo"))
frame_element = session.find.css("iframe", all=False)
session.switch_frame(frame_element)
stale_element = session.find.css("p", all=False)
element = session.find.css("p", all=False)
result = switch_to_parent_frame(session)
assert_success(result)
with pytest.raises(StaleElementReferenceException):
stale_element.text
with pytest.raises(NoSuchElementException):
element.text
def test_switch_from_top_level(session, inline):