Update web-platform-tests to revision b464d69274950c7707855c0b29729d58b9a8d492

This commit is contained in:
WPT Sync Bot 2020-12-05 08:22:48 +00:00
parent 93c31df551
commit b505991695
92 changed files with 1750 additions and 119 deletions

View file

@ -4,7 +4,7 @@
expected: TIMEOUT expected: TIMEOUT
[Opening a blob URL in a new window immediately before revoking it works.] [Opening a blob URL in a new window immediately before revoking it works.]
expected: FAIL expected: TIMEOUT
[Fetching a blob URL immediately before revoking it works in an iframe.] [Fetching a blob URL immediately before revoking it works in an iframe.]
expected: FAIL expected: FAIL

View file

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

View file

@ -2,3 +2,6 @@
[Hit test intersecting scaled box] [Hit test intersecting scaled box]
expected: FAIL expected: FAIL
[Hit test within unscaled box]
expected: FAIL

View file

@ -1,4 +0,0 @@
[elementFromPoint-001.html]
[CSSOM View - 5 - extensions to the Document interface]
expected: FAIL

View file

@ -2,3 +2,6 @@
[elementsFromPoint on the root document for points in iframe elements] [elementsFromPoint on the root document for points in iframe elements]
expected: FAIL expected: FAIL
[elementsFromPoint on inner documents]
expected: FAIL

View file

@ -0,0 +1,4 @@
[elementsFromPoint-invalid-cases.html]
[The root element is the last element returned for otherwise empty queries within the viewport]
expected: FAIL

View file

@ -0,0 +1,2 @@
[selectors-dir-selector-auto.html]
expected: ERROR

View file

@ -0,0 +1,2 @@
[selectors-dir-selector-change-001.html]
expected: FAIL

View file

@ -0,0 +1,2 @@
[selectors-dir-selector-change-002.html]
expected: FAIL

View file

@ -0,0 +1,2 @@
[selectors-dir-selector-change-003.html]
expected: FAIL

View file

@ -0,0 +1,2 @@
[selectors-dir-selector-change-004.html]
expected: FAIL

View file

@ -0,0 +1,10 @@
[selectors-dir-selector-querySelector.html]
[:dir() works in compound selectors]
expected: FAIL
[:dir() works in complex selectors]
expected: FAIL
[:dir() allows any ident value but strings other than ltr/rtl don't match]
expected: FAIL

View file

@ -0,0 +1,2 @@
[selectors-dir-selector-white-space-001.html]
expected: FAIL

View file

@ -309,21 +309,18 @@
[Response: combined response Content-Type: text/html;" \\" text/plain ";charset=GBK] [Response: combined response Content-Type: text/html;" \\" text/plain ";charset=GBK]
expected: NOTRUN expected: NOTRUN
[<iframe>: combined response Content-Type: text/html;" text/plain]
expected: FAIL
[<iframe>: separate response Content-Type: text/plain */*;charset=gbk]
expected: FAIL
[<iframe>: combined response Content-Type: */* text/html] [<iframe>: combined response Content-Type: */* text/html]
expected: FAIL expected: FAIL
[<iframe>: separate response Content-Type: text/plain */*] [<iframe>: separate response Content-Type: text/html */*;charset=gbk]
expected: FAIL expected: FAIL
[<iframe>: combined response Content-Type: text/html;" \\" text/plain] [<iframe>: combined response Content-Type: text/html */*;charset=gbk]
expected: FAIL expected: FAIL
[<iframe>: combined response Content-Type: text/html;x=" text/plain] [<iframe>: separate response Content-Type: text/html;x=" text/plain]
expected: FAIL
[<iframe>: separate response Content-Type: text/html;" \\" text/plain]
expected: FAIL expected: FAIL

View file

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

View file

@ -11,3 +11,6 @@
[X-Content-Type-Options%3A%20nosniff%2C%2C%40%23%24%23%25%25%26%5E%26%5E*()()11!] [X-Content-Type-Options%3A%20nosniff%2C%2C%40%23%24%23%25%25%26%5E%26%5E*()()11!]
expected: FAIL expected: FAIL
[X-Content-Type-Options%3A%20'NosniFF']
expected: FAIL

View file

@ -1,4 +0,0 @@
[traverse_the_history_1.html]
[Multiple history traversals from the same task]
expected: FAIL

View file

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

View file

@ -0,0 +1,2 @@
[cross-origin-objects-on-new-window.html]
expected: TIMEOUT

View file

@ -1,4 +1,5 @@
[embedded-opener-remove-frame.html] [embedded-opener-remove-frame.html]
expected: CRASH
[opener of discarded nested browsing context] [opener of discarded nested browsing context]
expected: FAIL expected: FAIL

View file

@ -1,5 +1,5 @@
[iframe_sandbox_popups_escaping-1.html] [iframe_sandbox_popups_escaping-1.html]
expected: TIMEOUT expected: CRASH
[Check that popups from a sandboxed iframe escape the sandbox if\n allow-popups-to-escape-sandbox is used] [Check that popups from a sandboxed iframe escape the sandbox if\n allow-popups-to-escape-sandbox is used]
expected: TIMEOUT expected: TIMEOUT

View file

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

View file

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

View file

@ -1,4 +0,0 @@
[form-double-submit-2.html]
[preventDefault should allow onclick submit() to succeed]
expected: FAIL

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

@ -1,4 +0,0 @@
[form-double-submit.html]
[default submit action should supersede onclick submit()]
expected: FAIL

View file

@ -11,3 +11,15 @@
[Form newline normalization: \\r in the name becomes \\r\\n] [Form newline normalization: \\r in the name becomes \\r\\n]
expected: FAIL expected: FAIL
[Form newline normalization: \\r\\n in the filename stays unchanged]
expected: FAIL
[Form newline normalization: \\n in the filename stays unchanged]
expected: FAIL
[Form newline normalization: \\r in the filename stays unchanged]
expected: FAIL
[Form newline normalization: \\n\\r in the filename stays unchanged]
expected: FAIL

View file

@ -1,4 +0,0 @@
[iframe_005.html]
[document.write external script into iframe write back into parent]
expected: FAIL

View file

@ -3,6 +3,3 @@
[The incumbent settings object while executing the compiled callback via Web IDL's invoke must be that of the node document] [The incumbent settings object while executing the compiled callback via Web IDL's invoke must be that of the node document]
expected: TIMEOUT expected: TIMEOUT
[The entry settings object while executing the compiled callback via Web IDL's invoke must be that of the node document]
expected: FAIL

View file

@ -359,3 +359,9 @@
[X SNR (-47.5135609418513 dB) is not greater than or equal to 65.737. Got -47.5135609418513.] [X SNR (-47.5135609418513 dB) is not greater than or equal to 65.737. Got -47.5135609418513.]
expected: FAIL expected: FAIL
[X SNR (-47.70129108083442 dB) is not greater than or equal to 65.737. Got -47.70129108083442.]
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\]\t3.6039609375000000e+4\t9.3139332532882690e-1\t3.6038677981674671e+4\t3.8693296378252737e+4\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 3.6038677981674671e+4 at index of 28696.\n\tMax RelError of 3.8693296378252737e+4 at index of 28696.\n]
expected: FAIL

View file

@ -0,0 +1,5 @@
[017.html]
expected: TIMEOUT
[origin of the script that invoked the method, about:blank]
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,2 +0,0 @@
[Worker-constructor.html]
expected: ERROR

View file

@ -7,7 +7,7 @@
expected: FAIL expected: FAIL
[Opening a blob URL in a new window immediately before revoking it works.] [Opening a blob URL in a new window immediately before revoking it works.]
expected: FAIL expected: TIMEOUT
[Opening a blob URL in a noopener about:blank window immediately before revoking it works.] [Opening a blob URL in a noopener about:blank window immediately before revoking it works.]
expected: TIMEOUT expected: TIMEOUT

View file

@ -153416,6 +153416,19 @@
{} {}
] ]
], ],
"abs-pos-004.html": [
"b66143c36c135e2dc535cdf7efee3bbed8952f17",
[
null,
[
[
"/css/css-grid/subgrid/abs-pos-004-ref.html",
"=="
]
],
{}
]
],
"auto-track-sizing-001.html": [ "auto-track-sizing-001.html": [
"0fdb9b0b7e2ed8855b02dcfb9baceeb61b7d05d3", "0fdb9b0b7e2ed8855b02dcfb9baceeb61b7d05d3",
[ [
@ -225183,6 +225196,58 @@
{} {}
] ]
], ],
"selectors-dir-selector-change-001.html": [
"f952389643834f4a67062bf722d5ce4422253094",
[
null,
[
[
"/css/selectors/selectors-dir-selector-change-001-ref.html",
"=="
]
],
{}
]
],
"selectors-dir-selector-change-002.html": [
"bc032b59541335d49f7ffe56919cfad9b7cd2fee",
[
null,
[
[
"/css/reference/ref-filled-green-100px-square.xht",
"=="
]
],
{}
]
],
"selectors-dir-selector-change-003.html": [
"f4000155a8d5004b401ce5964f535979cc4ec256",
[
null,
[
[
"/css/selectors/selectors-dir-selector-change-003-ref.html",
"=="
]
],
{}
]
],
"selectors-dir-selector-change-004.html": [
"4c76b291bad7ffde21d624a3abc03c7b3cc99ac9",
[
null,
[
[
"/css/selectors/selectors-dir-selector-change-004-ref.html",
"=="
]
],
{}
]
],
"selectors-dir-selector-ltr-001.html": [ "selectors-dir-selector-ltr-001.html": [
"9b90832a218debcf98a8a23bed7b0e679bd472ac", "9b90832a218debcf98a8a23bed7b0e679bd472ac",
[ [
@ -225196,6 +225261,32 @@
{} {}
] ]
], ],
"selectors-dir-selector-ltr-002.html": [
"bbb3f26a780b13d434d99ca858b44f7db635047b",
[
null,
[
[
"/css/reference/ref-filled-green-100px-square.xht",
"=="
]
],
{}
]
],
"selectors-dir-selector-ltr-003.html": [
"821a33616fca6940618d3e27c07963eba4c0f748",
[
null,
[
[
"/css/reference/ref-filled-green-100px-square.xht",
"=="
]
],
{}
]
],
"selectors-dir-selector-rtl-001.html": [ "selectors-dir-selector-rtl-001.html": [
"9b7bfd090a3c6736c3a30329912558c3c31f32fc", "9b7bfd090a3c6736c3a30329912558c3c31f32fc",
[ [
@ -225209,6 +225300,19 @@
{} {}
] ]
], ],
"selectors-dir-selector-white-space-001.html": [
"d3128a03734dc9806e3136ef6657b6087d9d76fa",
[
null,
[
[
"/css/selectors/selectors-dir-selector-white-space-001-ref.html",
"=="
]
],
{}
]
],
"selectors-empty-001.xml": [ "selectors-empty-001.xml": [
"3b882debcc717c3e85de8695476eca3fd5238e8a", "3b882debcc717c3e85de8695476eca3fd5238e8a",
[ [
@ -260813,6 +260917,12 @@
"19a0bfaed3f0aa1b498c275ac43100dbcb23010b", "19a0bfaed3f0aa1b498c275ac43100dbcb23010b",
[] []
], ],
"resources": {
"concatenate-stream.js": [
"a35bb1416e754893e331c0089d97720ae3b5af8e",
[]
]
},
"third_party": { "third_party": {
"pako": { "pako": {
"LICENSE": [ "LICENSE": [
@ -312587,6 +312697,10 @@
"19180106e548c8a183ba903b7b9c6f3e443d79a9", "19180106e548c8a183ba903b7b9c6f3e443d79a9",
[] []
], ],
"abs-pos-004-ref.html": [
"ac47309df22993903294406748b4152b27ff0a33",
[]
],
"auto-track-sizing-001-ref.html": [ "auto-track-sizing-001-ref.html": [
"800f87e5d00a767f1cb5e5816ffd46110fbd4e80", "800f87e5d00a767f1cb5e5816ffd46110fbd4e80",
[] []
@ -328592,6 +328706,22 @@
"3b768b36a50cd46c3fae0de91c63f8231fde7811", "3b768b36a50cd46c3fae0de91c63f8231fde7811",
[] []
], ],
"selectors-dir-selector-change-001-ref.html": [
"8c79c8328f0b2bf88b320956efdd689a97130550",
[]
],
"selectors-dir-selector-change-003-ref.html": [
"8c79c8328f0b2bf88b320956efdd689a97130550",
[]
],
"selectors-dir-selector-change-004-ref.html": [
"9a130cb2e5c71b9948e68022ad6ef89cc0ecda05",
[]
],
"selectors-dir-selector-white-space-001-ref.html": [
"955a2dd603d625975934e1ed6a42b4ea077093b7",
[]
],
"selectors-empty-001-ref.xml": [ "selectors-empty-001-ref.xml": [
"3f1b3f42a89399fec3ca03c4f69aa1e75527a0a3", "3f1b3f42a89399fec3ca03c4f69aa1e75527a0a3",
[] []
@ -369193,7 +369323,7 @@
] ]
}, },
"setup.py": [ "setup.py": [
"759cb48d1f65f52f6500ed2b871c7ef430518ab6", "a9cc95f4c1a532b5682de4db367899ad9c5de284",
[] []
], ],
"tests": { "tests": {
@ -393845,6 +393975,69 @@
} }
] ]
], ],
"compression-with-detach.tentative.any.js": [
"786bba21c800ca9f067a6d033f0345a52bfbb218",
[
"compression/compression-with-detach.tentative.any.html",
{
"script_metadata": [
[
"global",
"window,worker"
],
[
"script",
"resources/concatenate-stream.js"
]
]
}
],
[
"compression/compression-with-detach.tentative.any.serviceworker.html",
{
"script_metadata": [
[
"global",
"window,worker"
],
[
"script",
"resources/concatenate-stream.js"
]
]
}
],
[
"compression/compression-with-detach.tentative.any.sharedworker.html",
{
"script_metadata": [
[
"global",
"window,worker"
],
[
"script",
"resources/concatenate-stream.js"
]
]
}
],
[
"compression/compression-with-detach.tentative.any.worker.html",
{
"script_metadata": [
[
"global",
"window,worker"
],
[
"script",
"resources/concatenate-stream.js"
]
]
}
]
],
"decompression-bad-chunks.tentative.any.js": [ "decompression-bad-chunks.tentative.any.js": [
"ba609a5625b959362222f85371628827f44d8768", "ba609a5625b959362222f85371628827f44d8768",
[ [
@ -394205,6 +394398,69 @@
} }
] ]
], ],
"decompression-with-detach.tentative.any.js": [
"a2f8bda09148f0d323022b1f93be78d83c4aa654",
[
"compression/decompression-with-detach.tentative.any.html",
{
"script_metadata": [
[
"global",
"window,worker"
],
[
"script",
"resources/concatenate-stream.js"
]
]
}
],
[
"compression/decompression-with-detach.tentative.any.serviceworker.html",
{
"script_metadata": [
[
"global",
"window,worker"
],
[
"script",
"resources/concatenate-stream.js"
]
]
}
],
[
"compression/decompression-with-detach.tentative.any.sharedworker.html",
{
"script_metadata": [
[
"global",
"window,worker"
],
[
"script",
"resources/concatenate-stream.js"
]
]
}
],
[
"compression/decompression-with-detach.tentative.any.worker.html",
{
"script_metadata": [
[
"global",
"window,worker"
],
[
"script",
"resources/concatenate-stream.js"
]
]
}
]
],
"idlharness.https.any.js": [ "idlharness.https.any.js": [
"8d96cf523c495389ec5bfdea921a65d4dd0cd1e3", "8d96cf523c495389ec5bfdea921a65d4dd0cd1e3",
[ [
@ -415507,7 +415763,7 @@
] ]
], ],
"column-widths.html": [ "column-widths.html": [
"52cb5b6fb0502cd63e2404168cfd413d86d60b6e", "b151c2263bb625c0ec4bd2e2159b7bf15602fc63",
[ [
null, null,
{} {}
@ -426621,6 +426877,20 @@
{} {}
] ]
], ],
"selectors-dir-selector-auto.html": [
"d53e989f69e172ea8cb0eb0a11863c767f4f5bf2",
[
null,
{}
]
],
"selectors-dir-selector-querySelector.html": [
"a05e3fea78f378e37c1b73f7f9e2e3559db12f16",
[
null,
{}
]
],
"user-invalid.html": [ "user-invalid.html": [
"05cf2b679039c61732054217cf562bfeb7c3d23a", "05cf2b679039c61732054217cf562bfeb7c3d23a",
[ [
@ -485253,7 +485523,7 @@
] ]
], ],
"newline-normalization.html": [ "newline-normalization.html": [
"d3de7699662da75fc37fba31cf994f02a13de191", "b49468e19991e9309282e3068efff859d1c66751",
[ [
null, null,
{} {}
@ -499961,6 +500231,15 @@
} }
] ]
], ],
"MediaStreamTrack-clone.https.html": [
"c2b3e2bf8ab1b8c32cdc207181240c695e202656",
[
null,
{
"testdriver": true
}
]
],
"MediaStreamTrack-getCapabilities-fast.html": [ "MediaStreamTrack-getCapabilities-fast.html": [
"55272d1499517a6fda0b7e06068928b4e1127b27", "55272d1499517a6fda0b7e06068928b4e1127b27",
[ [
@ -503092,7 +503371,7 @@
] ]
], ],
"showPicker-errors.https.window.js": [ "showPicker-errors.https.window.js": [
"e8f0d3f540485120cd15d642b1b0d33110797098", "d1dabf37da8305094bf7e0bd0fea4e0200d8dd2e",
[ [
"native-file-system/showPicker-errors.https.window.html", "native-file-system/showPicker-errors.https.window.html",
{ {
@ -530263,7 +530542,7 @@
], ],
"readable-byte-streams": { "readable-byte-streams": {
"bad-buffers-and-views.any.js": [ "bad-buffers-and-views.any.js": [
"0777208da44b29b822bf9345dbe20e33bb5708b9", "d4ad483d9c39566b8bc5b4d09676d05eac8879e5",
[ [
null, null,
{ {
@ -545686,7 +545965,7 @@
] ]
], ],
"ctor-audiobuffer.html": [ "ctor-audiobuffer.html": [
"9845d5eaba384cced3c63ddbf4df1400b31f4994", "fbe6e42e3178f84d108bfd1c62518a4d13eb2dff",
[ [
null, null,
{} {}

View file

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

View file

@ -2,3 +2,6 @@
[Hit test intersecting scaled box] [Hit test intersecting scaled box]
expected: FAIL expected: FAIL
[Hit test within unscaled box]
expected: FAIL

View file

@ -1,4 +0,0 @@
[elementFromPoint-001.html]
[CSSOM View - 5 - extensions to the Document interface]
expected: FAIL

View file

@ -2,3 +2,6 @@
[elementsFromPoint on the root document for points in iframe elements] [elementsFromPoint on the root document for points in iframe elements]
expected: FAIL expected: FAIL
[elementsFromPoint on inner documents]
expected: FAIL

View file

@ -0,0 +1,4 @@
[elementsFromPoint-invalid-cases.html]
[The root element is the last element returned for otherwise empty queries within the viewport]
expected: FAIL

View file

@ -0,0 +1,2 @@
[selectors-dir-selector-auto.html]
expected: ERROR

View file

@ -0,0 +1,2 @@
[selectors-dir-selector-change-001.html]
expected: FAIL

View file

@ -0,0 +1,2 @@
[selectors-dir-selector-change-002.html]
expected: FAIL

View file

@ -0,0 +1,2 @@
[selectors-dir-selector-change-003.html]
expected: FAIL

View file

@ -0,0 +1,2 @@
[selectors-dir-selector-change-004.html]
expected: FAIL

View file

@ -0,0 +1,10 @@
[selectors-dir-selector-querySelector.html]
[:dir() works in compound selectors]
expected: FAIL
[:dir() works in complex selectors]
expected: FAIL
[:dir() allows any ident value but strings other than ltr/rtl don't match]
expected: FAIL

View file

@ -0,0 +1,2 @@
[selectors-dir-selector-white-space-001.html]
expected: FAIL

View file

@ -309,21 +309,18 @@
[fetch(): separate response Content-Type: text/plain ] [fetch(): separate response Content-Type: text/plain ]
expected: NOTRUN expected: NOTRUN
[<iframe>: combined response Content-Type: text/html;" text/plain]
expected: FAIL
[<iframe>: separate response Content-Type: text/plain */*;charset=gbk]
expected: FAIL
[<iframe>: combined response Content-Type: */* text/html] [<iframe>: combined response Content-Type: */* text/html]
expected: FAIL expected: FAIL
[<iframe>: separate response Content-Type: text/plain */*] [<iframe>: separate response Content-Type: text/html */*;charset=gbk]
expected: FAIL expected: FAIL
[<iframe>: combined response Content-Type: text/html;" \\" text/plain] [<iframe>: combined response Content-Type: text/html */*;charset=gbk]
expected: FAIL expected: FAIL
[<iframe>: combined response Content-Type: text/html;x=" text/plain] [<iframe>: separate response Content-Type: text/html;x=" text/plain]
expected: FAIL
[<iframe>: separate response Content-Type: text/html;" \\" text/plain]
expected: FAIL expected: FAIL

View file

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

View file

@ -11,3 +11,6 @@
[X-Content-Type-Options%3A%20nosniff%2C%2C%40%23%24%23%25%25%26%5E%26%5E*()()11!] [X-Content-Type-Options%3A%20nosniff%2C%2C%40%23%24%23%25%25%26%5E%26%5E*()()11!]
expected: FAIL expected: FAIL
[X-Content-Type-Options%3A%20'NosniFF']
expected: FAIL

View file

@ -1,4 +0,0 @@
[traverse_the_history_1.html]
[Multiple history traversals from the same task]
expected: FAIL

View file

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

View file

@ -0,0 +1,2 @@
[cross-origin-objects-on-new-window.html]
expected: TIMEOUT

View file

@ -1,4 +1,5 @@
[embedded-opener-remove-frame.html] [embedded-opener-remove-frame.html]
expected: CRASH
[opener and "removed" embedded documents] [opener and "removed" embedded documents]
expected: FAIL expected: FAIL

View file

@ -1,6 +1,6 @@
[iframe_sandbox_popups_escaping-1.html] [iframe_sandbox_popups_escaping-1.html]
type: testharness type: testharness
expected: TIMEOUT expected: CRASH
[Check that popups from a sandboxed iframe escape the sandbox if\n allow-popups-to-escape-sandbox is used] [Check that popups from a sandboxed iframe escape the sandbox if\n allow-popups-to-escape-sandbox is used]
expected: TIMEOUT expected: TIMEOUT

View file

@ -1,6 +1,6 @@
[iframe_sandbox_popups_nonescaping-1.html] [iframe_sandbox_popups_nonescaping-1.html]
type: testharness type: testharness
expected: CRASH expected: TIMEOUT
[Check that popups from a sandboxed iframe do not escape the sandbox] [Check that popups from a sandboxed iframe do not escape the sandbox]
expected: NOTRUN expected: NOTRUN

View file

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

View file

@ -1,4 +0,0 @@
[form-double-submit-2.html]
[preventDefault should allow onclick submit() to succeed]
expected: FAIL

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

@ -1,4 +0,0 @@
[form-double-submit.html]
[default submit action should supersede onclick submit()]
expected: FAIL

View file

@ -11,3 +11,15 @@
[Form newline normalization: \\r in the name becomes \\r\\n] [Form newline normalization: \\r in the name becomes \\r\\n]
expected: FAIL expected: FAIL
[Form newline normalization: \\r\\n in the filename stays unchanged]
expected: FAIL
[Form newline normalization: \\n in the filename stays unchanged]
expected: FAIL
[Form newline normalization: \\r in the filename stays unchanged]
expected: FAIL
[Form newline normalization: \\n\\r in the filename stays unchanged]
expected: FAIL

View file

@ -1,4 +0,0 @@
[iframe_005.html]
[document.write external script into iframe write back into parent]
expected: FAIL

View file

@ -4,6 +4,3 @@
[The incumbent settings object while executing the compiled callback via Web IDL's invoke must be that of the node document] [The incumbent settings object while executing the compiled callback via Web IDL's invoke must be that of the node document]
expected: TIMEOUT expected: TIMEOUT
[The entry settings object while executing the compiled callback via Web IDL's invoke must be that of the node document]
expected: FAIL

View file

@ -587,3 +587,9 @@
[X SNR (-47.5135609418513 dB) is not greater than or equal to 65.737. Got -47.5135609418513.] [X SNR (-47.5135609418513 dB) is not greater than or equal to 65.737. Got -47.5135609418513.]
expected: FAIL expected: FAIL
[X SNR (-47.70129108083442 dB) is not greater than or equal to 65.737. Got -47.70129108083442.]
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\]\t3.6039609375000000e+4\t9.3139332532882690e-1\t3.6038677981674671e+4\t3.8693296378252737e+4\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 3.6038677981674671e+4 at index of 28696.\n\tMax RelError of 3.8693296378252737e+4 at index of 28696.\n]
expected: FAIL

View file

@ -0,0 +1,5 @@
[017.html]
expected: TIMEOUT
[origin of the script that invoked the method, about:blank]
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,2 +0,0 @@
[Worker-constructor.html]
expected: ERROR

View file

@ -0,0 +1,55 @@
// META: global=window,worker
// META: script=resources/concatenate-stream.js
'use strict';
const kInputLength = 500000;
function createLargeRandomInput() {
const buffer = new ArrayBuffer(kInputLength);
// The getRandomValues API will only let us get 65536 bytes at a time, so call
// it multiple times.
const kChunkSize = 65536;
for (let offset = 0; offset < kInputLength; offset += kChunkSize) {
const length =
offset + kChunkSize > kInputLength ? kInputLength - offset : kChunkSize;
const view = new Uint8Array(buffer, offset, length);
crypto.getRandomValues(view);
}
return new Uint8Array(buffer);
}
function decompress(view) {
const ds = new DecompressionStream('deflate');
const writer = ds.writable.getWriter();
writer.write(view);
writer.close();
return concatenateStream(ds.readable);
}
promise_test(async () => {
const input = createLargeRandomInput();
const inputCopy = input.slice(0, input.byteLength);
const cs = new CompressionStream('deflate');
const writer = cs.writable.getWriter();
writer.write(input);
writer.close();
// Object.prototype.then will be looked up synchronously when the promise
// returned by read() is resolved.
Object.defineProperty(Object.prototype, 'then', {
get() {
// Cause input to become detached and unreferenced.
try {
postMessage(undefined, 'nowhere', [input.buffer]);
} catch (e) {
// It's already detached.
}
}
});
const output = await concatenateStream(cs.readable);
// Perform the comparison as strings since this is reasonably fast even when
// JITted JavaScript is running under an emulator.
assert_equals(
inputCopy.toString(), (await decompress(output)).toString(),
'decompressing the output should return the input');
}, 'data should be correctly compressed even if input is detached partway');

View file

@ -0,0 +1,41 @@
// META: global=window,worker
// META: script=resources/concatenate-stream.js
'use strict';
const kInputLength = 1000000;
async function createLargeCompressedInput() {
const cs = new CompressionStream('deflate');
// The input has to be large enough that it won't fit in a single chunk when
// decompressed.
const writer = cs.writable.getWriter();
writer.write(new Uint8Array(kInputLength));
writer.close();
return concatenateStream(cs.readable);
}
promise_test(async () => {
const input = await createLargeCompressedInput();
const ds = new DecompressionStream('deflate');
const writer = ds.writable.getWriter();
writer.write(input);
writer.close();
// Object.prototype.then will be looked up synchronously when the promise
// returned by read() is resolved.
Object.defineProperty(Object.prototype, 'then', {
get() {
// Cause input to become detached and unreferenced.
try {
postMessage(undefined, 'nowhere', [input.buffer]);
} catch (e) {
// It's already detached.
}
}
});
const output = await concatenateStream(ds.readable);
// If output successfully decompressed and gave the right length, we can be
// reasonably confident that no data corruption happened.
assert_equals(
output.byteLength, kInputLength, 'output should be the right length');
}, 'data should be correctly decompressed even if input is detached partway');

View file

@ -0,0 +1,25 @@
'use strict';
// Read all the chunks from a stream that returns BufferSource objects and
// concatenate them into a single Uint8Array.
async function concatenateStream(readableStream) {
const reader = readableStream.getReader();
let totalSize = 0;
const buffers = [];
while (true) {
const { value, done } = await reader.read();
if (done) {
break;
}
buffers.push(value);
totalSize += value.byteLength;
}
reader.releaseLock();
const concatenated = new Uint8Array(totalSize);
let offset = 0;
for (const buffer of buffers) {
concatenated.set(buffer, offset);
offset += buffer.byteLength;
}
return concatenated;
}

View file

@ -0,0 +1,198 @@
<!DOCTYPE HTML>
<!--
Any copyright is dedicated to the Public Domain.
http://creativecommons.org/publicdomain/zero/1.0/
-->
<html><head>
<title>Reference: abs.pos. subgrid edge cases</title>
<link rel="author" title="Mats Palmgren" href="mailto:mats@mozilla.com">
<style>
html,body {
color:black; background-color:white; font:15px/1 monospace;
}
body > div {
display: inline-block;
height: 20px;
border: 1px solid;
margin: 1px;
vertical-align: top;
}
body > div > div { height: 20px; background: lightgrey; }
body > div > div > div { height: 20px; }
</style>
</head>
<body>
<script>
let results = [
[ "10px", "0", "10px", "0", "10px", "lime" ],
[ "10px", "0", "10px", "0", "10px", "lime" ],
[ "10px", "0", "10px", "0", "10px", "lime" ],
[ "10px", "0", "10px", "0", "10px", "lime" ],
[ "10px", "0", "10px", "0", "10px", "lime" ],
[ "10px", "0", "10px", "0", "10px", "lime" ],
[ "10px", "0", "10px", "0", "10px", "lime" ],
[ "10px", "0", "10px", "0", "10px", "lime" ],
[ "10px", "0", "10px", "0", "10px", "lime" ],
[ "10px", "0", "10px", "0", "10px", "lime" ],
[ "10px", "0", "10px", "0", "10px", "lime" ],
[ "10px", "0", "10px", "0", "10px", "lime" ],
[ "50px", "0", "50px", "0", "10px", "lime" ],
[ "50px", "0", "50px", "0", "10px", "lime" ],
[ "50px", "0", "50px", "0", "50px", "lime" ],
[ "50px", "0", "50px", "0", "10px", "lime" ],
[ "50px", "0", "50px", "0", "10px", "lime" ],
[ "50px", "0", "50px", "0", "50px", "lime" ],
[ "50px", "0", "40px", "0", "40px", "lime" ],
[ "50px", "0", "40px", "0", "40px", "lime" ],
[ "50px", "0", "40px", "0", "40px", "lime" ],
[ "50px", "0", "40px", "0", "40px", "lime" ],
[ "50px", "0", "40px", "0", "40px", "lime" ],
[ "50px", "0", "40px", "0", "40px", "lime" ],
[ "10px", "0", "10px", "0", "10px", "blue" ],
[ "10px", "0", "10px", "0", "10px", "blue" ],
[ "10px", "0", "10px", "0", "10px", "blue" ],
[ "10px", "0", "10px", "0", "10px", "blue" ],
[ "10px", "0", "10px", "0", "10px", "blue" ],
[ "10px", "0", "10px", "0", "10px", "blue" ],
[ "10px", "0", "10px", "0", "10px", "blue" ],
[ "10px", "0", "10px", "0", "10px", "blue" ],
[ "10px", "0", "10px", "0", "10px", "blue" ],
[ "10px", "0", "10px", "0", "10px", "blue" ],
[ "10px", "0", "10px", "0", "10px", "blue" ],
[ "10px", "0", "10px", "0", "10px", "blue" ],
[ "50px", "0", "50px", "0", "10px", "blue" ],
[ "50px", "0", "50px", "0", "10px", "blue" ],
[ "50px", "0", "50px", "0", "50px", "blue" ],
[ "50px", "0", "50px", "0", "10px", "blue" ],
[ "50px", "0", "50px", "0", "10px", "blue" ],
[ "50px", "0", "50px", "0", "50px", "blue" ],
[ "50px", "0", "40px", "0", "40px", "blue" ],
[ "50px", "0", "40px", "0", "40px", "blue" ],
[ "50px", "0", "40px", "0", "40px", "blue" ],
[ "50px", "0", "40px", "0", "40px", "blue" ],
[ "50px", "0", "40px", "0", "40px", "blue" ],
[ "50px", "0", "40px", "0", "40px", "blue" ],
[ "20px", "0", "20px", "0", "20px", "lime" ],
[ "20px", "0", "20px", "0", "20px", "lime" ],
[ "20px", "0", "20px", "0", "20px", "lime" ],
[ "20px", "0", "20px", "0", "20px", "lime" ],
[ "20px", "0", "20px", "0", "20px", "lime" ],
[ "20px", "0", "20px", "0", "20px", "lime" ],
[ "20px", "0", "20px", "0", "20px", "lime" ],
[ "20px", "0", "20px", "0", "20px", "lime" ],
[ "20px", "0", "20px", "0", "20px", "lime" ],
[ "20px", "0", "20px", "0", "20px", "lime" ],
[ "20px", "0", "20px", "0", "20px", "lime" ],
[ "20px", "0", "20px", "0", "20px", "lime" ],
[ "50px", "0", "0", "20px", "30px", "lime" ],
[ "50px", "0", "0", "20px", "30px", "lime" ],
[ "50px", "0", "0", "20px", "30px", "lime" ],
[ "50px", "0", "0", "20px", "30px", "lime" ],
[ "50px", "0", "0", "20px", "30px", "lime" ],
[ "50px", "0", "0", "20px", "30px", "lime" ],
[ "50px", "0", "0", "0", "30px", "lime" ],
[ "50px", "0", "0", "0", "30px", "lime" ],
[ "50px", "0", "0", "0", "30px", "lime" ],
[ "50px", "0", "0", "0", "30px", "lime" ],
[ "50px", "0", "0", "0", "30px", "lime" ],
[ "50px", "0", "0", "0", "30px", "lime" ],
[ "20px", "0", "20px", "0", "20px", "blue" ],
[ "20px", "0", "20px", "0", "20px", "blue" ],
[ "20px", "0", "20px", "0", "20px", "blue" ],
[ "20px", "0", "20px", "0", "20px", "blue" ],
[ "20px", "0", "20px", "0", "20px", "blue" ],
[ "20px", "0", "20px", "0", "20px", "blue" ],
[ "20px", "0", "20px", "0", "20px", "blue" ],
[ "20px", "0", "20px", "0", "20px", "blue" ],
[ "20px", "0", "20px", "0", "20px", "blue" ],
[ "20px", "0", "20px", "0", "20px", "blue" ],
[ "20px", "0", "20px", "0", "20px", "blue" ],
[ "20px", "0", "20px", "0", "20px", "blue" ],
[ "50px", "0", "0", "20px", "30px", "blue" ],
[ "50px", "0", "0", "20px", "30px", "blue" ],
[ "50px", "0", "0", "20px", "30px", "blue" ],
[ "50px", "0", "0", "20px", "30px", "blue" ],
[ "50px", "0", "0", "20px", "30px", "blue" ],
[ "50px", "0", "0", "20px", "30px", "blue" ],
[ "50px", "0", "0", "0", "30px", "blue" ],
[ "50px", "0", "0", "0", "30px", "blue" ],
[ "50px", "0", "0", "0", "30px", "blue" ],
[ "50px", "0", "0", "0", "30px", "blue" ],
[ "50px", "0", "0", "0", "30px", "blue" ],
[ "50px", "0", "0", "0", "30px", "blue" ],
[ "30px", "0", "30px", "0", "30px", "lime" ],
[ "30px", "0", "30px", "0", "30px", "lime" ],
[ "30px", "0", "30px", "0", "30px", "lime" ],
[ "30px", "0", "30px", "0", "30px", "lime" ],
[ "30px", "0", "30px", "0", "30px", "lime" ],
[ "30px", "0", "30px", "0", "30px", "lime" ],
[ "30px", "0", "30px", "0", "30px", "lime" ],
[ "30px", "0", "30px", "0", "30px", "lime" ],
[ "30px", "0", "30px", "0", "30px", "lime" ],
[ "30px", "0", "30px", "0", "30px", "lime" ],
[ "30px", "0", "30px", "0", "30px", "lime" ],
[ "30px", "0", "30px", "0", "30px", "lime" ],
[ "50px", "20px", "30px", "0", "10px", "lime" ],
[ "50px", "20px", "30px", "0", "10px", "lime" ],
[ "50px", "0", "0", "20px", "30px", "lime" ],
[ "50px", "20px", "30px", "0", "10px", "lime" ],
[ "50px", "20px", "30px", "0", "10px", "lime" ],
[ "50px", "0", "0", "20px", "30px", "lime" ],
[ "50px", "0", "0", "0", "20px", "lime" ],
[ "50px", "0", "0", "0", "20px", "lime" ],
[ "50px", "0", "0", "0", "20px", "lime" ],
[ "50px", "0", "0", "0", "20px", "lime" ],
[ "50px", "0", "0", "0", "20px", "lime" ],
[ "50px", "0", "0", "0", "20px", "lime" ],
[ "30px", "0", "30px", "0", "30px", "blue" ],
[ "30px", "0", "30px", "0", "30px", "blue" ],
[ "30px", "0", "30px", "0", "30px", "blue" ],
[ "30px", "0", "30px", "0", "30px", "blue" ],
[ "30px", "0", "30px", "0", "30px", "blue" ],
[ "30px", "0", "30px", "0", "30px", "blue" ],
[ "30px", "0", "30px", "0", "30px", "blue" ],
[ "30px", "0", "30px", "0", "30px", "blue" ],
[ "30px", "0", "30px", "0", "30px", "blue" ],
[ "30px", "0", "30px", "0", "30px", "blue" ],
[ "30px", "0", "30px", "0", "30px", "blue" ],
[ "30px", "0", "30px", "0", "30px", "blue" ],
[ "50px", "20px", "30px", "0", "10px", "blue" ],
[ "50px", "20px", "30px", "0", "10px", "blue" ],
[ "50px", "0", "0", "20px", "30px", "blue" ],
[ "50px", "20px", "30px", "0", "10px", "blue" ],
[ "50px", "20px", "30px", "0", "10px", "blue" ],
[ "50px", "0", "0", "20px", "30px", "blue" ],
[ "50px", "0", "0", "0", "20px", "blue" ],
[ "50px", "0", "0", "0", "20px", "blue" ],
[ "50px", "0", "0", "0", "20px", "blue" ],
[ "50px", "0", "0", "0", "20px", "blue" ],
[ "50px", "0", "0", "0", "20px", "blue" ],
[ "50px", "0", "0", "0", "20px", "blue" ],
];
results.forEach(function(arr) {
let grid_width, subgrid_width, subgrid_pos, item_pos, item_width, item_bg;
[grid_width, subgrid_pos, subgrid_width, item_pos, item_width, item_bg] = arr;
let grid = document.createElement('div');
grid.style.width = grid_width;
let subgrid = document.createElement('div');
subgrid.style.width = subgrid_width;
subgrid.style.marginLeft = subgrid_pos;
let subgridItem = document.createElement('div');
subgridItem.style.width = item_width;
subgridItem.style.marginLeft = item_pos;
subgridItem.style.backgroundColor = item_bg;
subgrid.appendChild(subgridItem);
grid.appendChild(subgrid);
document.body.appendChild(grid);
});
</script>
</body>
</html>

View file

@ -0,0 +1,104 @@
<!DOCTYPE HTML>
<!--
Any copyright is dedicated to the Public Domain.
http://creativecommons.org/publicdomain/zero/1.0/
-->
<html><head>
<title>CSS Grid Test: abs.pos. subgrid edge cases</title>
<link rel="author" title="Mats Palmgren" href="mailto:mats@mozilla.com">
<link rel="help" href="https://drafts.csswg.org/css-grid-2">
<link rel="match" href="abs-pos-004-ref.html">
<style>
html,body {
color:black; background-color:white; font:15px/1 monospace;
}
.grid {
position: relative;
display: inline-grid;
grid-auto-columns: 10px;
grid-auto-rows: 20px;
grid-auto-flow: column;
border: 1px solid;
margin: 1px;
vertical-align: top;
}
.subgrid {
position: absolute;
inset: 0;
display: grid;
background: lightgrey;
}
.t1 { grid: subgrid / subgrid; }
.t2 { grid: none / subgrid; }
.t3 { grid: subgrid / none; }
x {
background: lime;
grid-area: 1/1/-1/-1;
}
fail {
background: red;
}
.a {
position: absolute;
grid-area: 1/1/-1/-1;
inset: 0;
background: blue;
}
.o { overflow: hidden; }
.start .subgrid {
grid-column-start: 3;
}
.end .subgrid {
grid-column-end: 1;
}
.start, .end {
width: 50px;
}
.end {
justify-content: end;
}
.start > fail, .end > fail {
background: initial;
}
</style>
</head>
<body>
<script>
function make_grids(items, abspos) {
["", "o", "start", "end"].forEach(function(grid1) {
["", "o"].forEach(function(subgrid1) {
["t1", "t2", "t3"].forEach(function(subgrid2) {
let grid = document.createElement('div');
for (let i = 0; i < items; ++i) {
grid.appendChild(document.createElement('fail'));
}
grid.className = "grid " + grid1;
document.body.appendChild(grid);
document.body.offsetHeight;
let subgrid = document.createElement('div');
subgrid.className = "subgrid " + subgrid1 + " " + subgrid2;
let subgridItem = document.createElement('x');
if (abspos) {
subgridItem.className = "a";
}
subgrid.appendChild(subgridItem);
grid.appendChild(subgrid);
})
})
});
}
for (let i = 1; i <= 3; ++i) {
make_grids(i, false);
make_grids(i, true);
}
</script>
</body>
</html>

View file

@ -276,7 +276,23 @@ column.max = max(td.max, col.max)</p>
<table style="width:1px" data-expected-width=234> <table style="width:1px" data-expected-width=234>
<col style="width:50%"> <col style="width:50%">
<td style="width:100px" data-expected-width=10><div style="width:10px">10</div></td> <td style="width:100px" data-expected-width=10><div style="width:10px">10</div></td>
<td><div style="width:200px">200</div> <td><div style="width:200px">200</div></td>
</table>
<p class="testdesc">col fixed td fixed inside table-layout:fixed
constrained columns take precedence in fixed layout.
<table style="width:324px;table-layout:fixed" data-expected-width=324>
<col style="width:100px">
<td style="width:200px" data-expected-width=100>100</td>
<td data-expected-width=200><div style="width:400px" >200</div></td>
</table>
<p class="testdesc">col percent td fixed inside table-layout:fixed
constrained columns take precedence in fixed layout.
<table style="width:324px;table-layout:fixed" data-expected-width=324>
<col style="width:50%">
<td style="width:200px" data-expected-width=150>150</td>
<td><div style="width:400px">150</div></td>
</table> </table>
</main> </main>
<script> <script>

View file

@ -0,0 +1,93 @@
<!doctype html>
<html>
<head>
<link rel="help" href="http://www.w3.org/TR/selectors4/#dir-pseudo">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<style>
#div4_1 {
direction: rtl;
}
</style>
</head>
<!-- &#1514; is the Hebrew letter tav, i.e. RTL -->
<body>
<div id=testDivs>
<div id=div1 dir=auto>
<div id=div1_1>a</div>
</div>
<div id=div2 dir=auto>
<div id=div2_1>&#1514;</div>
</div>
<div id=div3 dir=auto>
<div id=div3_1 dir=rtl>&#1514;</div>
<div id=div3_2>a</div>
</div>
<div id=div4 dir=auto>
<div id=div4_1>
<div id=div4_1_1>a</div>
</div>
</div>
</div>
</body>
<script>
function test_directionality(message, element, expected) {
test(() => {
var isLTR = document.querySelector("#" + element.id + ":dir(ltr)") == element;
var isRTL = document.querySelector("#" + element.id + ":dir(rtl)") == element;
if (expected == "ltr") {
assert_true(isLTR);
assert_false(isRTL);
} else {
assert_false(isLTR);
assert_true(isRTL);
}
}, message + " directionality of element " + element.id + " is " + expected);
}
test_directionality("Initial ", div1, "ltr");
test_directionality("Initial ", div1_1, "ltr");
test_directionality("Initial ", div2, "rtl");
test_directionality("Initial ", div2_1, "rtl");
test_directionality("Initial ", div3, "ltr");
test_directionality("Initial ", div3_1, "rtl");
test_directionality("Initial ", div3_2, "ltr");
test_directionality("Initial ", div4, "ltr");
test_directionality("Initial ", div4_1, "ltr");
test_directionality("Initial ", div4_1_1, "ltr");
div1_1.innerText = "\u05EA";
div1_1.offsetTop;
test_directionality("Updated ", div1, "rtl");
test_directionality("Updated ", div1_1, "rtl");
div1_1.dir = "ltr";
div1_1.offsetTop;
test_directionality("Updated ", div1, "ltr");
test_directionality("Updated ", div1_1, "ltr");
div1_1.innerText = "a";
div1_1.offsetTop;
test_directionality("Reupdated ", div1, "ltr");
test_directionality("Reupdated ", div1_1, "ltr");
div2_1.remove();
div2.offsetTop;
test_directionality("Updated ", div2, "ltr");
div3_1.dir = "";
div3_1.offsetTop;
test_directionality("Updated ", div3, "rtl");
div3.appendChild(div3_1);
div3.offsetTop;
test_directionality("Updated ", div3, "ltr");
div4_1_1.innerText = "\u05EA";
div4_1_1.offsetTop;
test_directionality("Updated ", div4, "rtl");
test_directionality("Updated ", div4_1, "rtl");
test_directionality("Updated ", div4_1_1, "rtl");
</script>
</html>

View file

@ -0,0 +1,16 @@
<!DOCTYPE html>
<html>
<head>
<style type="text/css">
span { background-color: lime }
</style>
</head>
<body>
<div>
<div>
<div></div>
<span>The background color should be lime</span>
</div>
</div>
</body>
</html>

View file

@ -0,0 +1,25 @@
<!DOCTYPE html>
<html>
<head>
<title>CSS Selectors Level 4 Test: Check for correctly updating :dir matching on dir attribute change from default(ltr) to rtl</title>
<link rel="author" title="Miyoung Shin" href="mailto:myid.shin@igalia.com">
<link rel="help" href="http://www.w3.org/TR/selectors4/#dir-pseudo">
<link rel="match" href="selectors-dir-selector-change-001-ref.html">
<style type="text/css">
#x:dir(rtl) + span { background-color: lime }
#outer { direction:ltr }
</style>
</head>
<body>
<div id="outer" style="-webkit-locale: 'en'">
<div>
<div id="x"></div>
<span>The background color should be lime</span>
</div>
</div>
<script>
outer.offsetTop;
outer.setAttribute("dir", "rtl");
</script>
</body>
</html>

View file

@ -0,0 +1,28 @@
<!DOCTYPE html>
<html>
<head>
<title>CSS Selectors Level 4 Test: Check for correctly updating :dir matching on dir attribute change from default(ltr) to rtl</title>
<link rel="author" title="Miyoung Shin" href="mailto:myid.shin@igalia.com">
<link rel="help" href="http://www.w3.org/TR/selectors4/#dir-pseudo">
<link rel="match" href="../reference/ref-filled-green-100px-square.xht">
<style type="text/css">
div {
width: 100px;
height: 100px;
background-color: red;
}
div:dir(rtl) {
background-color: green;
}
</style>
</head>
<body>
<p>Test passes if there is a filled green square and <strong>no red</strong>.</p>
<div id="inner"></div>
<script>
inner.offsetTop;
inner.setAttribute("dir", "rtl");
</script>
</body>
</html>

View file

@ -0,0 +1,16 @@
<!DOCTYPE html>
<html>
<head>
<style type="text/css">
span { background-color: lime }
</style>
</head>
<body>
<div>
<div>
<div></div>
<span>The background color should be lime</span>
</div>
</div>
</body>
</html>

View file

@ -0,0 +1,24 @@
<!DOCTYPE html>
<html>
<head>
<title>CSS Selectors Level 4 Test: Check for correctly updating :dir matching on dir attribute change from rtl to auto</title>
<link rel="author" title="Miyoung Shin" href="mailto:myid.shin@igalia.com">
<link rel="help" href="http://www.w3.org/TR/selectors4/#dir-pseudo">
<link rel="match" href="selectors-dir-selector-change-003-ref.html">
<style type="text/css">
#x:dir(ltr) + span { background-color: lime }
</style>
</head>
<body>
<div id="outer" dir="rtl">
<div>
<div id="x"></div>
<span>The background color should be lime</span>
</div>
</div>
<script>
outer.offsetTop;
outer.setAttribute("dir", "auto");
</script>
</body>
</html>

View file

@ -0,0 +1,17 @@
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<style type="text/css">
span { background-color: lime }
</style>
</head>
<body>
<div>
<div dir="rtl">
<div></div>
<span>מקור השם עברית</span>
</div>
</div>
</body>
</html>

View file

@ -0,0 +1,25 @@
<!DOCTYPE html>
<html>
<head>
<title>CSS Selectors Level 4 Test: Check for correctly updating :dir matching on directionality change from ltr to rtl</title>
<link rel="author" title="Miyoung Shin" href="mailto:myid.shin@igalia.com">
<link rel="help" href="http://www.w3.org/TR/selectors4/#dir-pseudo">
<link rel="match" href="selectors-dir-selector-change-004-ref.html">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<style type="text/css">
#x:dir(rtl) + span { background-color: lime }
</style>
</head>
<body>
<div dir="auto">
<div>
<div id="x"></div>
<span id="inner">The background color should be lime</span>
</div>
</div>
<script>
inner.offsetTop;
inner.innerHTML = "מקור השם עברית";
</script>
</body>
</html>

View file

@ -0,0 +1,26 @@
<!DOCTYPE html>
<html>
<head>
<title>CSS Selectors Level 4 Test: exception handling for an invalid identifier of dir()</title>
<link rel="author" title="Miyoung Shin" href="mailto:myid.shin@igalia.com">
<link rel="help" href="http://www.w3.org/TR/selectors4/#dir-pseudo">
<link rel="match" href="../reference/ref-filled-green-100px-square.xht">
<meta name="flags" content="">
<meta name="assert" content="The invalid identifier of :dir(ltrr) pseudo-class doesn't match an element that has a directionality of (ltr). Even if the div element has dir=ltr, the selector should not match.">
<style type="text/css">
div {
width: 100px;
height: 100px;
background-color: green;
}
div:dir(ltrr) {
background-color: red;
}
</style>
</head>
<body>
<p>Test passes if there is a filled green square and <strong>no red</strong>.</p>
<div dir="ltr"></div>
</body>
</html>

View file

@ -0,0 +1,26 @@
<!DOCTYPE html>
<html>
<head>
<title>CSS Selectors Level 4 Test: exception handling for multiple identifiers of dir() </title>
<link rel="author" title="Miyoung Shin" href="mailto:myid.shin@igalia.com">
<link rel="help" href="http://www.w3.org/TR/selectors4/#dir-pseudo">
<link rel="match" href="../reference/ref-filled-green-100px-square.xht">
<meta name="flags" content="">
<meta name="assert" content="The multiple identifiers of :dir(ltr, rtl) pseudo-class don't match an element that has a directionality of (ltr). Even if the div element has dir=ltr, the selector should not match.">
<style type="text/css">
div {
width: 100px;
height: 100px;
background-color: green;
}
div:dir(ltr, rtl) {
background-color: red;
}
</style>
</head>
<body>
<p>Test passes if there is a filled green square and <strong>no red</strong>.</p>
<div dir="ltr"></div>
</body>
</html>

View file

@ -0,0 +1,71 @@
<!doctype html>
<html>
<head>
<link rel="help" href="http://www.w3.org/TR/selectors4/#dir-pseudo">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
</head>
<body>
<div id=outer>
<div id=div1></div>
<div id=div2 dir=ltr>
<div id=div2_1></div>
<div id=div2_2 dir=ltr></div>
<div id=div2_3 dir=rtl></div>
</div>
<div id=div3 dir=rtl>
<div id=div3_1>
<div id=div3_1_1></div>
</div>
<div id=div3_2 dir=ltr></div>
<div id=div3_3 dir=rtl></div>
</div>
<div id=div4 dir=lol></div>
<div id=div5 dir=auto></div>
</div>
</body>
<script>
test(() => {
assert_equals(document.querySelector(":dir(lol)"), null);
assert_equals(document.querySelector(":dir(lol )"), null);
assert_equals(document.querySelector(":dir( auto)"), null);
assert_equals(document.querySelector(":dir(\nauto\t)"), null);
}, ":dir() allows any ident value but strings other than ltr/rtl don't match");
test(() => {
assert_throws_dom("SYNTAX_ERR", () => { document.querySelector(":dir()"); });
assert_throws_dom("SYNTAX_ERR", () => { document.querySelector(":dir(ltr, rtl)"); });
assert_throws_dom("SYNTAX_ERR", () => { document.querySelector(":dir('ltr')"); });
}, ":dir() requires exactly an ident argument");
test(() => {
assert_equals(document.querySelector(":dir(rtl)"), div2_3);
assert_equals(document.querySelector("*:dir(rtl)"), div2_3);
assert_equals(document.querySelector("div:dir(ltr)"), outer);
assert_equals(document.querySelector("div:dir(ltr):dir(ltr)"), outer);
assert_equals(document.querySelector(":dir(rtl)#div3_3"), div3_3);
assert_equals(document.querySelector(":nth-child(2):dir(rtl)"), null);
assert_equals(document.querySelector(":nth-child(3):dir(rtl)"), div2_3);
assert_equals(document.querySelector(":nth-child(4):dir(ltr)"), div4);
assert_equals(document.querySelector(":nth-last-child(3):dir(rtl)"), div3);
}, ":dir() works in compound selectors");
test(() => {
assert_equals(document.querySelector("#div2 :dir(ltr)"), div2_1);
assert_equals(document.querySelector(":dir(rtl) div"), div3_1);
assert_equals(document.querySelector("div + :dir(ltr)"), div2);
assert_equals(document.querySelector(":dir(ltr) + :dir(rtl)"), div2_3);
assert_equals(document.querySelector(":dir(rtl) :dir(rtl)"), div3_1);
assert_equals(document.querySelector(":dir(rtl) + :dir(ltr)"), div3_2);
assert_equals(document.querySelector(":dir(rtl) ~ :dir(rtl)"), div3_3);
assert_equals(document.querySelector(":dir(rtl) :dir(ltr)"), div3_2);
assert_equals(document.querySelector("* :dir(rtl) *"), div3_1);
assert_equals(document.querySelector("div :dir(rtl) div"), div3_1);
assert_equals(document.querySelector(":dir(ltr) :dir(rtl) + :dir(ltr)"), div3_2);
assert_equals(document.querySelector(":dir(ltr) + :dir(rtl) + * + *"), div5);
assert_equals(document.querySelector(":dir(rtl) > * > :dir(rtl)"), div3_1_1);
}, ":dir() works in complex selectors");
</script>
</html>

View file

@ -0,0 +1,18 @@
<!DOCTYPE html>
<html>
<head>
<style type="text/css">
div {
width: 100px;
height: 100px;
background-color: green;
}
</style>
</head>
<body>
<p>Test passes if there is a filled green square and <strong>no red</strong>.</p>
<div></div>
<div></div>
<div></div>
</body>
</html>

View file

@ -0,0 +1,27 @@
<!DOCTYPE html>
<html>
<head>
<title>CSS Selectors Level 4 Test: Verify for an identifier with leading and tailing whitespace of dir() </title>
<link rel="author" title="Miyoung Shin" href="mailto:myid.shin@igalia.com">
<link rel="help" href="http://www.w3.org/TR/selectors4/#dir-pseudo">
<link rel="match" href="selectors-dir-selector-white-space-001-ref.html">
<meta name="assert" content="The :dir(ltr) pseudo-class matches an element that has a directionality of (ltr). Since the div element has dir=ltr, the selector matches.">
<style type="text/css">
div {
width: 100px;
height: 100px;
background-color: red;
}
#a:dir( ltr) { background-color: green; }
#b:dir(ltr ) { background-color: green; }
#c:dir( ltr ) { background-color: green; }
</style>
</head>
<body>
<p>Test passes if there is a filled green square and <strong>no red</strong>.</p>
<div id="a" dir="ltr"></div>
<div id="b" dir="ltr"></div>
<div id="c" dir="ltr"></div>
</body>
</html>

View file

@ -22,6 +22,22 @@
return form; return form;
} }
function createFormWithFile(testCase, name, filename) {
const form = document.createElement("form");
const input = document.createElement("input");
input.type = "file";
input.name = name;
const dataTransfer = new DataTransfer();
dataTransfer.items.add(new File([], filename, { type: "text/plain" }));
input.files = dataTransfer.files;
form.appendChild(input);
document.body.appendChild(form);
testCase.add_cleanup(() => {
document.body.removeChild(form);
});
return form;
}
test((testCase) => { test((testCase) => {
const formData = new FormData(createForm(testCase, "a", "b\nc")); const formData = new FormData(createForm(testCase, "a", "b\nc"));
assert_equals(formData.get("a"), "b\r\nc"); assert_equals(formData.get("a"), "b\r\nc");
@ -61,6 +77,34 @@
const formData = new FormData(createForm(testCase, "a\n\rb", "c")); const formData = new FormData(createForm(testCase, "a\n\rb", "c"));
assert_equals([...formData][0][0], "a\r\n\r\nb"); assert_equals([...formData][0][0], "a\r\n\r\nb");
}, document.title + ": \\n\\r in the name becomes \\r\\n\\r\\n"); }, document.title + ": \\n\\r in the name becomes \\r\\n\\r\\n");
test((testCase) => {
const formData = new FormData(
createFormWithFile(testCase, "a", "b\nc")
);
assert_equals(formData.get("a").name, "b\nc");
}, document.title + ": \\n in the filename stays unchanged");
test((testCase) => {
const formData = new FormData(
createFormWithFile(testCase, "a", "b\rc")
);
assert_equals(formData.get("a").name, "b\rc");
}, document.title + ": \\r in the filename stays unchanged");
test((testCase) => {
const formData = new FormData(
createFormWithFile(testCase, "a", "b\r\nc")
);
assert_equals(formData.get("a").name, "b\r\nc");
}, document.title + ": \\r\\n in the filename stays unchanged");
test((testCase) => {
const formData = new FormData(
createFormWithFile(testCase, "a", "b\n\rc")
);
assert_equals(formData.get("a").name, "b\n\rc");
}, document.title + ": \\n\\r in the filename stays unchanged");
</script> </script>
</body> </body>
</html> </html>

View file

@ -0,0 +1,362 @@
<!DOCTYPE html>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="/resources/testdriver.js"></script>
<script src="/resources/testdriver-vendor.js"></script>
<script src="/mediacapture-image/resources/imagecapture-helpers.js"></script>
<script>
// This test verifies that we can set some nondefault constraints, then clone a
// MediaStreamTrack and check that the cloned constraints are the same as the
// original, with a mock Mojo service implementation.
image_capture_test(async (t, imageCaptureTest) => {
await test_driver.set_permission({name: 'camera', panTiltZoom: true},
'granted', false);
const constraints = { advanced : [{ whiteBalanceMode : 'single-shot',
exposureMode : 'manual',
focusMode : 'single-shot',
pointsOfInterest : [{x : 0.1, y : 0.2},
{x : 0.3, y : 0.4}],
exposureCompensation : 133.77,
exposureTime : 10000,
colorTemperature : 6000,
iso : 120.0,
brightness : 3,
contrast : 4,
saturation : 5,
sharpness : 6,
focusDistance : 7,
pan : 8,
tilt : 9,
zoom : 3.141592,
torch : true
}]};
let stream = await navigator.mediaDevices.getUserMedia({video: true});
let originalVideoTrack = stream.getVideoTracks()[0];
await originalVideoTrack.applyConstraints(constraints);
let appliedConstraints = originalVideoTrack.getConstraints();
let clonedVideoTrack = originalVideoTrack.clone();
let appliedClonedConstraints = clonedVideoTrack.getConstraints();
assert_true('advanced' in appliedClonedConstraints);
assert_equals(appliedClonedConstraints.advanced.length, 1);
const appliedClonedAdvancedConstraints = appliedClonedConstraints.advanced[0];
// Check that |appliedClonedAdvancedConstraints| and |appliedAdvancedConstraints| are equal.
const appliedAdvancedConstraints = appliedConstraints.advanced[0];
assert_equals(appliedAdvancedConstraints.length, appliedClonedAdvancedConstraints.length);
Object.keys(appliedClonedAdvancedConstraints).forEach((key, value) => {
assert_not_equals(appliedAdvancedConstraints[key], undefined, 'key ' + key);
if (key != 'pointsOfInterest') {
assert_equals(appliedAdvancedConstraints[key], appliedClonedAdvancedConstraints[key], key);
} else {
assert_point2d_array_approx_equals(appliedAdvancedConstraints[key],
appliedClonedAdvancedConstraints[key], 0.01);
}
});
assert_equals(appliedAdvancedConstraints.whiteBalanceMode,
appliedClonedAdvancedConstraints.whiteBalanceMode,
'whiteBalanceMode');
assert_equals(appliedAdvancedConstraints.exposureMode,
appliedClonedAdvancedConstraints.exposureMode,
'exposureMode');
assert_equals(appliedAdvancedConstraints.focusMode,
appliedClonedAdvancedConstraints.focusMode,
'focusMode');
assert_point2d_array_approx_equals(
appliedAdvancedConstraints.pointsOfInterest,
appliedClonedAdvancedConstraints.pointsOfInterest,
0.01);
assert_equals(appliedAdvancedConstraints.exposureCompensation,
appliedClonedAdvancedConstraints.exposureCompensation,
'exposureCompensation');
assert_equals(appliedAdvancedConstraints.exposureTime,
appliedClonedAdvancedConstraints.exposureTime,
'exposureTime');
assert_equals(appliedAdvancedConstraints.colorTemperature,
appliedClonedAdvancedConstraints.colorTemperature,
'colorTemperature');
assert_equals(appliedAdvancedConstraints.iso,
appliedClonedAdvancedConstraints.iso,
'iso');
assert_equals(appliedAdvancedConstraints.brightness,
appliedClonedAdvancedConstraints.brightness,
'brightness');
assert_equals(appliedAdvancedConstraints.contrast,
appliedClonedAdvancedConstraints.contrast,
'constrast');
assert_equals(appliedAdvancedConstraints.saturation,
appliedClonedAdvancedConstraints.saturation,
'saturation');
assert_equals(appliedAdvancedConstraints.sharpness,
appliedClonedAdvancedConstraints.sharpness,
'sharpness');
assert_equals(appliedAdvancedConstraints.focusDistance,
appliedClonedAdvancedConstraints.focusDistance,
'focusDistance');
assert_equals(appliedAdvancedConstraints.pan,
appliedClonedAdvancedConstraints.pan,
'pan');
assert_equals(appliedAdvancedConstraints.tilt,
appliedClonedAdvancedConstraints.tilt,
'tilt');
assert_equals(appliedAdvancedConstraints.zoom,
appliedClonedAdvancedConstraints.zoom,
'zoom');
assert_equals(appliedAdvancedConstraints.torch,
appliedClonedAdvancedConstraints.torch,
'torch');
}, 'checks MediaStreamTrack.clone() gets same applied constraints');
// This test verifies that MediaStreamTrack ImageCapture settings are copied
// when cloning a MediaStreamTrack.
image_capture_test(async (t, imageCaptureTest) => {
await test_driver.set_permission({name: 'camera', panTiltZoom: true},
'granted', false);
let stream = await navigator.mediaDevices.getUserMedia({video: true});
let originalVideoTrack = stream.getVideoTracks()[0];
let clonedVideoTrack = originalVideoTrack.clone();
let settings = originalVideoTrack.getSettings();
let clonedSettings = clonedVideoTrack.getSettings();
assert_equals(settings.whiteBalanceMode,
clonedSettings.whiteBalanceMode,
'whiteBalanceMode');
assert_equals(settings.exposureMode,
clonedSettings.exposureMode,
'exposureMode;');
assert_equals(settings.focusMode,
clonedSettings.focusMode,
'focusMode');
assert_point2d_array_approx_equals(
settings.pointsOfInterest,
clonedSettings.pointsOfInterest,
0.01);
assert_equals(settings.exposureCompensation,
clonedSettings.exposureCompensation,
'exposureCompensation');
assert_equals(settings.exposureTime,
clonedSettings.exposureTime,
'exposureTime');
assert_equals(settings.colorTemperature,
clonedSettings.colorTemperature,
'colorTemperature');
assert_equals(settings.iso,
clonedSettings.iso,
'iso');
assert_equals(settings.brightness,
clonedSettings.brightness,
'brightness');
assert_equals(settings.contrast,
clonedSettings.contrast,
'contrast');
assert_equals(settings.saturation,
clonedSettings.saturation,
'saturation');
assert_equals(settings.sharpness,
clonedSettings.sharpness,
'sharpness');
assert_equals(settings.focusDistance,
clonedSettings.focusDistance,
'focusDistance');
assert_equals(settings.pan,
clonedSettings.pan,
'pan');
assert_equals(settings.tilt,
clonedSettings.tilt,
'tilt');
assert_equals(settings.zoom,
clonedSettings.zoom,
'zoom');
assert_equals(settings.torch,
clonedSettings.torch,
'torch');
}, 'checks MediaStreamTrack.clone() gets same settings');
// This test verifies that MediaStreamTrack ImageCapture capabilities are copied
// when cloning a MediaStreamTrack.
image_capture_test(async (t, imageCaptureTest) => {
await test_driver.set_permission({name: 'camera', panTiltZoom: true},
'granted', false);
let stream = await navigator.mediaDevices.getUserMedia({video: true});
let originalVideoTrack = stream.getVideoTracks()[0];
let clonedVideoTrack = originalVideoTrack.clone();
let capabilities = originalVideoTrack.getCapabilities();
let clonedCapabilities = clonedVideoTrack.getCapabilities();
assert_equals(capabilities.whiteBalanceMode.length,
clonedCapabilities.whiteBalanceMode.length,
'whiteBalanceMode length');
for (i = 0; i < capabilities.whiteBalanceMode.length; ++i) {
assert_equals(capabilities.whiteBalanceMode[i],
clonedCapabilities.whiteBalanceMode[i],
'whiteBalanceMode');
}
assert_equals(capabilities.exposureMode.length,
clonedCapabilities.exposureMode.length,
'exposureMode length');
for (i = 0; i < capabilities.exposureMode.length; ++i) {
assert_equals(capabilities.exposureMode[i],
clonedCapabilities.exposureMode[i],
'exposureMode');
}
assert_equals(capabilities.focusMode.length,
clonedCapabilities.focusMode.length,
'focusMode length');
for (i = 0; i < capabilities.focusMode.length; ++i) {
assert_equals(capabilities.focusMode[i],
clonedCapabilities.focusMode[i],
'focusMode');
}
assert_equals(capabilities.exposureCompensation.max,
clonedCapabilities.exposureCompensation.max,
'exposureCompensation max');
assert_equals(capabilities.exposureCompensation.min,
clonedCapabilities.exposureCompensation.min,
'exposureCompensation min');
assert_equals(capabilities.exposureCompensation.step,
clonedCapabilities.exposureCompensation.step,
'exposureCompensation step');
assert_equals(capabilities.exposureTime.max,
clonedCapabilities.exposureTime.max,
'exposureTime max');
assert_equals(capabilities.exposureTime.min,
clonedCapabilities.exposureTime.min,
'exposureTime min');
assert_equals(capabilities.exposureTime.step,
clonedCapabilities.exposureTime.step,
'exposureTime step');
assert_equals(capabilities.colorTemperature.max,
clonedCapabilities.colorTemperature.max,
'colorTemperature max');
assert_equals(capabilities.colorTemperature.min,
clonedCapabilities.colorTemperature.min,
'colorTemperature min');
assert_equals(capabilities.colorTemperature.step,
clonedCapabilities.colorTemperature.step,
'colorTemperature step');
assert_equals(capabilities.iso.max,
clonedCapabilities.iso.max,
'iso max');
assert_equals(capabilities.iso.min,
clonedCapabilities.iso.min,
'iso min');
assert_equals(capabilities.iso.step,
clonedCapabilities.iso.step,
'iso step');
assert_equals(capabilities.brightness.max,
clonedCapabilities.brightness.max,
'brightness max');
assert_equals(capabilities.brightness.min,
clonedCapabilities.brightness.min,
'brightness min');
assert_equals(capabilities.brightness.step,
clonedCapabilities.brightness.step,
'brightness step');
assert_equals(capabilities.contrast.max,
clonedCapabilities.contrast.max,
'contrast max');
assert_equals(capabilities.contrast.min,
clonedCapabilities.contrast.min,
'contrast min');
assert_equals(capabilities.contrast.step,
clonedCapabilities.contrast.step,
'contrast step');
assert_equals(capabilities.saturation.max,
clonedCapabilities.saturation.max,
'saturation max');
assert_equals(capabilities.saturation.min,
clonedCapabilities.saturation.min,
'saturation min');
assert_equals(capabilities.saturation.step,
clonedCapabilities.saturation.step,
'saturation step');
assert_equals(capabilities.sharpness.max,
clonedCapabilities.sharpness.max,
'sharpness max');
assert_equals(capabilities.sharpness.min,
clonedCapabilities.sharpness.min,
'sharpness min');
assert_equals(capabilities.sharpness.step,
clonedCapabilities.sharpness.step,
'sharpness step');
assert_equals(capabilities.focusDistance.max,
clonedCapabilities.focusDistance.max,
'focusDistance max');
assert_equals(capabilities.focusDistance.min,
clonedCapabilities.focusDistance.min,
'focusDistance min');
assert_equals(capabilities.focusDistance.step,
clonedCapabilities.focusDistance.step,
'focusDistance step');
assert_equals(capabilities.pan.max,
clonedCapabilities.pan.max,
'pan max');
assert_equals(capabilities.pan.min,
clonedCapabilities.pan.min,
'pan min');
assert_equals(capabilities.pan.step,
clonedCapabilities.pan.step,
'pan step');
assert_equals(capabilities.tilt.max,
clonedCapabilities.tilt.max,
'tilt max');
assert_equals(capabilities.tilt.min,
clonedCapabilities.tilt.min,
'tilt min');
assert_equals(capabilities.tilt.step,
clonedCapabilities.tilt.step,
'tilt step');
assert_equals(capabilities.zoom.max,
clonedCapabilities.zoom.max,
'zoom max');
assert_equals(capabilities.zoom.min,
clonedCapabilities.zoom.min,
'zoom min');
assert_equals(capabilities.zoom.step,
clonedCapabilities.zoom.step,
'zoom step');
assert_equals(capabilities.torch,
clonedCapabilities.torch,
'torch');
}, 'checks MediaStreamTrack.clone() gets same capabilities');
</script>

View file

@ -80,9 +80,39 @@ function define_file_picker_error_tests(showPickerMethod) {
showPickerMethod + showPickerMethod +
': MIME type can\'t have invalid characters in subtype.'); ': MIME type can\'t have invalid characters in subtype.');
promise_test(async t => { const invalid_extensions = {
await promise_rejects_js(t, TypeError, self[showPickerMethod]({ '.extensiontoolong': 'extension length more than 16.',
types: [{accept: {'text/plain': ['.txt', 'txt']}}] '.txt.': 'extenstion ends with "."',
})); 'txt': 'extenstion does not start with "."',
}, showPickerMethod + ': extension has to start with ".".'); '.$txt' : 'illegal character "$"',
'.t<xt': 'illegal character "<"',
'.t/xt': 'illegal character "\"',
'.\txt': 'illegal character "/"',
'.txt\\': 'illegal characters "\\"',
'.txt?': 'illegal character "?"',
'.txt*': 'illegal character "*"',
'.{txt': 'illegal character "{"',
'.}txt': 'illegal character "}"',
' .txt': 'illegal whitespace at front of extension',
'. txt': 'illegal whitespace in extension',
'.txt ': 'illegal whitespace at end of extension',
'.\u202etxt\u202e' : 'illegal RTL character',
'.t\u00E6xt': 'non-ASCII character "æ"',
'.קום': 'non-ASCII character "קום"',
'.txt🙂': 'non-ASCII character "🙂"',
'.{txt}': 'illegal characters "{" and "}"',
}
for (const [extension, description] of Object.entries(invalid_extensions)) {
define_file_picker_extension_error_test(showPickerMethod, extension, description)
}
}
function define_file_picker_extension_error_test(showPickerMethod, extension, description) {
promise_test(async t => {
await promise_rejects_js(
t, TypeError,
self[showPickerMethod](
{ types: [{ accept: { 'text/plain': ['.txt', extension] } }] }));
}, showPickerMethod + ': invalid extension "' + extension + '". ' + description + ".");
} }

View file

@ -212,8 +212,7 @@ async_test(t => {
c.close(); c.close();
const zeroLengthView = new Uint8Array(view.buffer, 0, 0); assert_throws_js(TypeError, () => c.byobRequest.respondWithNewView(view));
assert_throws_js(TypeError, () => c.byobRequest.respondWithNewView(zeroLengthView));
}), }),
type: 'bytes' type: 'bytes'
}); });

View file

@ -1,7 +1,7 @@
from setuptools import setup from setuptools import setup
PACKAGE_VERSION = '3.0' PACKAGE_VERSION = '3.0'
deps = ["six>=1.8", "h2==3.0.1"] deps = ["six>=1.13.0", "h2==3.0.1"]
setup(name='wptserve', setup(name='wptserve',
version=PACKAGE_VERSION, version=PACKAGE_VERSION,

View file

@ -211,17 +211,19 @@
Promise Promise
.all([ .all([
c1.startRendering().then(function(resultBuffer) { c1.startRendering().then(function(resultBuffer) {
return should(resultBuffer.getChannelData(0), 'c1 result') return resultBuffer;
.beEqualToArray(data);
}), }),
c2.startRendering().then(function(resultBuffer) { c2.startRendering().then(function(resultBuffer) {
return should(resultBuffer.getChannelData(0), 'c2 result') return resultBuffer;
.beEqualToArray(data);
}), }),
]) ])
.then(returnValues => { .then(resultBuffers => {
let c1ResultValue = should(resultBuffers[0].getChannelData(0), 'c1 result')
.beEqualToArray(data);
let c2ResultValue = should(resultBuffers[1].getChannelData(0), 'c2 result')
.beEqualToArray(data);
should( should(
returnValues[0] && returnValues[1], c1ResultValue && c2ResultValue,
'AudioBuffer shared between two different contexts') 'AudioBuffer shared between two different contexts')
.message('correctly', 'incorrectly'); .message('correctly', 'incorrectly');
task.done(); task.done();