Update web-platform-tests to revision e257d80ac7151243d0fcf6f4d5397b0f3f3629cc

This commit is contained in:
WPT Sync Bot 2020-10-22 08:21:22 +00:00
parent 011458ba95
commit 09159edcc2
72 changed files with 613 additions and 276 deletions

View file

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

View file

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

View file

@ -1,4 +0,0 @@
[hit-test-floats-005.html]
[Miss clipped float]
expected: FAIL

View file

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

View file

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

View file

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

View file

@ -1,4 +1,36 @@
[idlharness.html]
[idlharness.any.worker.html]
[DOMRectReadOnly interface: operation fromRect(optional DOMRectInit)]
expected: FAIL
[DOMPointReadOnly interface: calling matrixTransform(optional DOMMatrixInit) on new DOMPoint() with too few arguments must throw TypeError]
expected: FAIL
[DOMPointReadOnly interface: operation matrixTransform(optional DOMMatrixInit)]
expected: FAIL
[DOMRect interface: operation fromRect(optional DOMRectInit)]
expected: FAIL
[DOMPointReadOnly interface: new DOMPoint() must inherit property "matrixTransform(optional DOMMatrixInit)" with the proper type]
expected: FAIL
[DOMRectReadOnly interface: calling fromRect(optional DOMRectInit) on new DOMRect() with too few arguments must throw TypeError]
expected: FAIL
[DOMRect interface: calling fromRect(optional DOMRectInit) on new DOMRect() with too few arguments must throw TypeError]
expected: FAIL
[DOMRectReadOnly interface: calling fromRect(optional DOMRectInit) on new DOMRectReadOnly() with too few arguments must throw TypeError]
expected: FAIL
[DOMPointReadOnly interface: new DOMPointReadOnly() must inherit property "matrixTransform(optional DOMMatrixInit)" with the proper type]
expected: FAIL
[DOMPointReadOnly interface: calling matrixTransform(optional DOMMatrixInit) on new DOMPointReadOnly() with too few arguments must throw TypeError]
expected: FAIL
[idlharness.any.html]
[DOMRectReadOnly interface: operation fromRect(optional DOMRectInit)]
expected: FAIL

View file

@ -0,0 +1,34 @@
[iso-2022-jp-encoder.html]
[iso-2022-jp encoder: Katakana SO/SI ESC]
expected: FAIL
[iso-2022-jp encoder: Katakana U+FFFD]
expected: FAIL
[iso-2022-jp encoder: jis0208]
expected: FAIL
[iso-2022-jp encoder: jis0208 U+FFFD]
expected: FAIL
[iso-2022-jp encoder: Katakana]
expected: FAIL
[iso-2022-jp encoder: basics]
expected: FAIL
[iso-2022-jp encoder: Roman U+FFFD]
expected: FAIL
[iso-2022-jp encoder: Roman SO/SI ESC]
expected: FAIL
[iso-2022-jp encoder: U+FFFD]
expected: FAIL
[iso-2022-jp encoder: jis0208 SO/SI ESC]
expected: FAIL
[iso-2022-jp encoder: SO/SI ESC]
expected: FAIL

View file

@ -318,18 +318,18 @@
[<iframe>: separate response Content-Type: text/plain */*]
expected: FAIL
[<iframe>: separate 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/plain */*;charset=gbk]
expected: FAIL
[<iframe>: combined response Content-Type: text/html */*]
expected: FAIL
[<iframe>: combined response Content-Type: text/html;x=" text/plain]
[<iframe>: separate response Content-Type: text/html */*]
expected: FAIL
[<iframe>: combined response Content-Type: text/html */*;charset=gbk]
expected: FAIL
[<iframe>: separate response Content-Type: text/html;x=" text/plain]
expected: FAIL
[<iframe>: separate response Content-Type: text/html;" \\" text/plain]
expected: FAIL

View file

@ -53,9 +53,3 @@
[combined text/javascript ]
expected: FAIL
[separate text/javascript ]
expected: FAIL
[separate text/javascript x/x]
expected: FAIL

View file

@ -1,4 +1,4 @@
[traverse_the_history_4.html]
[traverse_the_history_5.html]
[Multiple history traversals, last would be aborted]
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_escaping-1.html]
expected: TIMEOUT
[Check that popups from a sandboxed iframe escape the sandbox if\n allow-popups-to-escape-sandbox is used]
expected: FAIL
expected: TIMEOUT

View file

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

View file

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

View file

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

View file

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

View file

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

View file

@ -1,4 +0,0 @@
[module-static-import-delayed.html]
[document.write in an imported module]
expected: FAIL

View file

@ -173,3 +173,6 @@
[X SNR (-384.8602297044423 dB) is not greater than or equal to 65.737. Got -384.8602297044423.]
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\]\t1.7380608709161053e-27\t9.3139332532882690e-1\t9.3139332532882690e-1\t1.0000000000000000e+0\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.3139332532882690e-1 at index of 28696.\n\tMax RelError of 1.0000000000000000e+0 at index of 28696.\n]
expected: FAIL

View file

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

View file

@ -461,6 +461,15 @@
{}
]
],
"crashtests": {
"trailing-space-with-cr-crash.html": [
"48c223e352d378e10b7cc10e5e49e8613e43c380",
[
null,
{}
]
]
},
"ellisize-rtl-text-crash.html": [
"88908877d668067c9c80fab1391f3c5f4e0dd53b",
[
@ -153561,12 +153570,12 @@
]
],
"image-orientation-none-cross-origin-canvas.html": [
"4d370e8e189667368035ecb7e65ba9cc03ba982f",
"d6123bee72c879c5971184eb672388b071cd313c",
[
null,
[
[
"/css/css-images/image-orientation/reference/image-orientation-none-cross-origin-ref.html",
"/css/css-images/image-orientation/reference/image-orientation-none-cross-origin-canvas-ref.html",
"=="
]
],
@ -310597,7 +310606,7 @@
[]
],
"image-orientation-none-cross-origin-canvas-ref.html": [
"4f9bc74620d8be7d94b8639a51764e04c2c5e685",
"1bd691075f0d29d3580e2103c3b30768f50f3031",
[]
],
"image-orientation-none-cross-origin-ref.html": [
@ -325798,10 +325807,6 @@
"dommatrix-test-util.js": [
"af860e2913cc72db92b5573e45725d7fa50c3fb0",
[]
],
"interfaces.js": [
"3dca6956a38876071be27db25302a0e9f64f03e6",
[]
]
}
},
@ -348941,7 +348946,7 @@
]
},
"lint.ignore": [
"4edf456bdd69975cfb668fa59c9aa2efa19fa7f8",
"2d0508fd9ba180ff4909a3d4e5c8cb1e195eb854",
[]
],
"loading": {
@ -349916,12 +349921,16 @@
[]
],
"dedicated-worker": {
"mediasource-worker-must-fail-if-unsupported.js": [
"69c65f6aa24b449cdf056faf42fb3ccc827889a9",
[]
],
"mediasource-worker-objecturl.js": [
"db47da0c0a658f456b9c0cb682db2fee2859931d",
"9a7195fc5bda04e4de95ba43bd2123a79685449a",
[]
],
"mediasource-worker-util.js": [
"4cee4862fa4e6c39c43fee7af1a332e8a7cd7ce2",
"7688a40fa6cf2e6bf9698601feab71cc439b2b98",
[]
]
},
@ -354627,7 +354636,7 @@
[]
],
"no-title.html": [
"ae1333a0f7f890b1b5e44a8a5ef3116fd4f5885b",
"baefb81bf8fac51e2767e2e623887cd0b96d8f1d",
[]
],
"order.html": [
@ -354924,7 +354933,7 @@
[]
],
"testharness.js": [
"4fb8cea0bcc167c99448c5b680276ebb1413cb5e",
"1c4f6414178575fb3fa47a5c7836e97bbb7e6668",
[]
],
"testharness.js.headers": [
@ -357290,12 +357299,24 @@
[]
],
"scope1": {
"module-worker-importing-redirect-to-scope2.js": [
"ae681ba30e0b01f1ec6c642ad4dac19f0cc9dc69",
[]
],
"module-worker-importing-scope2.js": [
"e28505249c281735441830319a9468beba8bb547",
[]
],
"redirect.py": [
"bb4c874aacee9479bd690bfae8dc956378d1ee64",
[]
]
},
"scope2": {
"imported-module-script.js": [
"a18e704a3c58fbde39928d2acbfc0950f56c45ec",
[]
],
"worker_interception_redirect_webworker.py": [
"bb4c874aacee9479bd690bfae8dc956378d1ee64",
[]
@ -365860,7 +365881,7 @@
[]
],
"test_wpt.py": [
"f0a9524c90a49073f3e24a9d65d6374b793575bb",
"02b611e378b8877651e15aee2ce2fc445ab4b57f",
[]
]
},
@ -366699,7 +366720,7 @@
[]
],
"base.py": [
"d3ffff6176260115a464fce7d36fe1923f42fcd9",
"7ce53a590b6518f4ab0abf3f0f3c91ee93019fef",
[]
],
"docroot": {
@ -368897,7 +368918,7 @@
[]
],
"refine.py": [
"3a6d63e04ce941d26ab3898cb2fc2a730d46c1ce",
"d5d24e934f61684be8512d120a4853bff7efadef",
[]
],
"test_actions_scroll_wdspec.html": [
@ -400710,7 +400731,7 @@
],
"parsing": {
"contain-computed.html": [
"9d36ada95b833724e20e5c0a9f69cd4064219d06",
"f25db353a077761d0f2f65beb2cc735c6c0496ff",
[
null,
{}
@ -402535,6 +402556,13 @@
{}
]
],
"svg-root-as-flex-item-006.html": [
"73406c8e864860479f61141d7694ac2e96a93ec7",
[
null,
{}
]
],
"table-as-item-cross-size.html": [
"ba788bdd72eb2e121f6baab26f6dd7df364f6301",
[
@ -422466,18 +422494,37 @@
{}
]
],
"idlharness.html": [
"b120700373076fb7ef818e22e7c12fefeff7bee5",
"idlharness.any.js": [
"5c9170b8a61a73dc192d1ee5f330733453f3a168",
[
null,
{}
]
],
"idlharness.worker.js": [
"fad617b2e02f65b8ac80b0445018697d0c7667ba",
"css/geometry/idlharness.any.html",
{
"script_metadata": [
[
"script",
"/resources/WebIDLParser.js"
],
[
"script",
"/resources/idlharness.js"
]
]
}
],
[
"css/geometry/idlharness.worker.html",
{}
"css/geometry/idlharness.any.worker.html",
{
"script_metadata": [
[
"script",
"/resources/WebIDLParser.js"
],
[
"script",
"/resources/idlharness.js"
]
]
}
]
],
"spec-examples.html": [
@ -429737,7 +429784,7 @@
]
],
"iso-2022-jp-encoder.html": [
"81bd18039b23d320ac36ffbff21aefe130cfe0b0",
"fa08375d9e0e3811eaea9ed57f20a6afb1739cbb",
[
null,
{}
@ -486452,7 +486499,7 @@
]
],
"click_iframe_crossorigin.sub.html": [
"01833dc23d4e9f2c5033dfbc052a4decbca02161",
"df2b4477cacfe6ca766cd97faa441a651e9f1d8e",
[
null,
{
@ -486524,7 +486571,7 @@
]
],
"virtual_authenticator.html": [
"204c95608b51036f99369946e2db796d6d1a5108",
"04c14719d41f2b8143ab348269d35b3f90cbc457",
[
null,
{
@ -489903,21 +489950,21 @@
],
"dedicated-worker": {
"mediasource-worker-objecturl.html": [
"382a9a4f3632a53cd2a94dab121fe34a07d9238d",
"378bd9fb2fd49b3096f8959ae2d1840938f4e6a9",
[
null,
{}
]
],
"mediasource-worker-play-terminate-worker.html": [
"69f2cbaaea37c5936bfc871af1996c134f52d0a3",
"138e9ecfe6efcc4508717d4b2ea9edcb786e9222",
[
null,
{}
]
],
"mediasource-worker-play.html": [
"200f8a851bfc396861ad93b501bcebd7209dffd6",
"336cb8f3f655761e59acb50dadd4204c6ac4235c",
[
null,
{}
@ -515201,6 +515248,13 @@
{}
]
],
"registration-scope-module-static-import.https.html": [
"5c75295aed1cd94c1349dc25010801534bd98644",
[
null,
{}
]
],
"registration-scope.https.html": [
"141875f5847c399f5dbf35431a558ad885428cbc",
[

View file

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

View file

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

View file

@ -1,4 +0,0 @@
[hit-test-floats-005.html]
[Miss clipped float]
expected: FAIL

View file

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

View file

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

View file

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

View file

@ -0,0 +1,123 @@
[idlharness.any.worker.html]
[DOMRectReadOnly interface: operation fromRect(optional DOMRectInit)]
expected: FAIL
[DOMPointReadOnly interface: calling matrixTransform(optional DOMMatrixInit) on new DOMPoint() with too few arguments must throw TypeError]
expected: FAIL
[DOMPointReadOnly interface: operation matrixTransform(optional DOMMatrixInit)]
expected: FAIL
[DOMRect interface: operation fromRect(optional DOMRectInit)]
expected: FAIL
[DOMPointReadOnly interface: new DOMPoint() must inherit property "matrixTransform(optional DOMMatrixInit)" with the proper type]
expected: FAIL
[DOMRectReadOnly interface: calling fromRect(optional DOMRectInit) on new DOMRect() with too few arguments must throw TypeError]
expected: FAIL
[DOMRect interface: calling fromRect(optional DOMRectInit) on new DOMRect() with too few arguments must throw TypeError]
expected: FAIL
[DOMRectReadOnly interface: calling fromRect(optional DOMRectInit) on new DOMRectReadOnly() with too few arguments must throw TypeError]
expected: FAIL
[DOMPointReadOnly interface: new DOMPointReadOnly() must inherit property "matrixTransform(optional DOMMatrixInit)" with the proper type]
expected: FAIL
[DOMPointReadOnly interface: calling matrixTransform(optional DOMMatrixInit) on new DOMPointReadOnly() with too few arguments must throw TypeError]
expected: FAIL
[idlharness.any.html]
[DOMRectReadOnly interface: operation fromRect(optional DOMRectInit)]
expected: FAIL
[DOMPointReadOnly interface: calling matrixTransform(optional DOMMatrixInit) on new DOMPoint() with too few arguments must throw TypeError]
expected: FAIL
[DOMRectList interface: existence and properties of interface prototype object's "constructor" property]
expected: FAIL
[DOMRectList interface: existence and properties of interface prototype object]
expected: FAIL
[DOMPointReadOnly interface: operation matrixTransform(optional DOMMatrixInit)]
expected: FAIL
[DOMRectList interface: [object DOMRect\] must inherit property "length" with the proper type]
expected: FAIL
[DOMRect interface: operation fromRect(optional DOMRectInit)]
expected: FAIL
[DOMRectList interface: operation item(unsigned long)]
expected: FAIL
[DOMMatrixReadOnly interface: stringifier]
expected: FAIL
[DOMRectList interface: existence and properties of interface object]
expected: FAIL
[DOMRectList interface object name]
expected: FAIL
[DOMRectList interface: [object DOMRect\] must inherit property "item(unsigned long)" with the proper type]
expected: FAIL
[DOMPointReadOnly interface: new DOMPoint() must inherit property "matrixTransform(optional DOMMatrixInit)" with the proper type]
expected: FAIL
[DOMMatrix interface: operation setMatrixValue(DOMString)]
expected: FAIL
[DOMRectReadOnly interface: calling fromRect(optional DOMRectInit) on new DOMRect() with too few arguments must throw TypeError]
expected: FAIL
[DOMRect interface: calling fromRect(optional DOMRectInit) on new DOMRect() with too few arguments must throw TypeError]
expected: FAIL
[DOMPoint interface: legacy window alias]
expected: FAIL
[DOMRectReadOnly interface: calling fromRect(optional DOMRectInit) on new DOMRectReadOnly() with too few arguments must throw TypeError]
expected: FAIL
[DOMRectList interface object length]
expected: FAIL
[DOMMatrix interface: calling setMatrixValue(DOMString) on new DOMMatrix() with too few arguments must throw TypeError]
expected: FAIL
[DOMPointReadOnly interface: new DOMPointReadOnly() must inherit property "matrixTransform(optional DOMMatrixInit)" with the proper type]
expected: FAIL
[DOMRect interface: legacy window alias]
expected: FAIL
[DOMRectList interface: calling item(unsigned long) on [object DOMRect\] with too few arguments must throw TypeError]
expected: FAIL
[DOMMatrix interface: new DOMMatrix() must inherit property "setMatrixValue(DOMString)" with the proper type]
expected: FAIL
[DOMRectList must be primary interface of [object DOMRect\]]
expected: FAIL
[DOMPointReadOnly interface: calling matrixTransform(optional DOMMatrixInit) on new DOMPointReadOnly() with too few arguments must throw TypeError]
expected: FAIL
[DOMRectList interface: attribute length]
expected: FAIL
[DOMMatrix interface: legacy window alias]
expected: FAIL
[Stringification of [object DOMRect\]]
expected: FAIL
[DOMRectList interface: existence and properties of interface prototype object's @@unscopables property]
expected: FAIL

View file

@ -1,31 +0,0 @@
[idlharness.worker.html]
[DOMRectReadOnly interface: operation fromRect(optional DOMRectInit)]
expected: FAIL
[DOMPointReadOnly interface: calling matrixTransform(optional DOMMatrixInit) on new DOMPoint() with too few arguments must throw TypeError]
expected: FAIL
[DOMPointReadOnly interface: operation matrixTransform(optional DOMMatrixInit)]
expected: FAIL
[DOMRect interface: operation fromRect(optional DOMRectInit)]
expected: FAIL
[DOMPointReadOnly interface: new DOMPoint() must inherit property "matrixTransform(optional DOMMatrixInit)" with the proper type]
expected: FAIL
[DOMRectReadOnly interface: calling fromRect(optional DOMRectInit) on new DOMRect() with too few arguments must throw TypeError]
expected: FAIL
[DOMRect interface: calling fromRect(optional DOMRectInit) on new DOMRect() with too few arguments must throw TypeError]
expected: FAIL
[DOMRectReadOnly interface: calling fromRect(optional DOMRectInit) on new DOMRectReadOnly() with too few arguments must throw TypeError]
expected: FAIL
[DOMPointReadOnly interface: new DOMPointReadOnly() must inherit property "matrixTransform(optional DOMMatrixInit)" with the proper type]
expected: FAIL
[DOMPointReadOnly interface: calling matrixTransform(optional DOMMatrixInit) on new DOMPointReadOnly() with too few arguments must throw TypeError]
expected: FAIL

View file

@ -7,3 +7,30 @@
[iso-2022-jp encoder: U+FFFD]
expected: FAIL
[iso-2022-jp encoder: Katakana SO/SI ESC]
expected: FAIL
[iso-2022-jp encoder: Katakana U+FFFD]
expected: FAIL
[iso-2022-jp encoder: jis0208]
expected: FAIL
[iso-2022-jp encoder: jis0208 U+FFFD]
expected: FAIL
[iso-2022-jp encoder: Katakana]
expected: FAIL
[iso-2022-jp encoder: Roman U+FFFD]
expected: FAIL
[iso-2022-jp encoder: Roman SO/SI ESC]
expected: FAIL
[iso-2022-jp encoder: jis0208 SO/SI ESC]
expected: FAIL
[iso-2022-jp encoder: SO/SI ESC]
expected: FAIL

View file

@ -318,18 +318,18 @@
[<iframe>: separate response Content-Type: text/plain */*]
expected: FAIL
[<iframe>: separate 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/plain */*;charset=gbk]
expected: FAIL
[<iframe>: combined response Content-Type: text/html */*]
expected: FAIL
[<iframe>: combined response Content-Type: text/html;x=" text/plain]
[<iframe>: separate response Content-Type: text/html */*]
expected: FAIL
[<iframe>: combined response Content-Type: text/html */*;charset=gbk]
expected: FAIL
[<iframe>: separate response Content-Type: text/html;x=" text/plain]
expected: FAIL
[<iframe>: separate response Content-Type: text/html;" \\" text/plain]
expected: FAIL

View file

@ -53,9 +53,3 @@
[combined text/javascript ]
expected: FAIL
[separate text/javascript ]
expected: FAIL
[separate text/javascript x/x]
expected: FAIL

View file

@ -1,4 +1,4 @@
[traverse_the_history_4.html]
[traverse_the_history_5.html]
[Multiple history traversals, last would be aborted]
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,5 +1,6 @@
[iframe_sandbox_popups_escaping-1.html]
type: testharness
expected: TIMEOUT
[Check that popups from a sandboxed iframe escape the sandbox if\n allow-popups-to-escape-sandbox is used]
expected: FAIL
expected: TIMEOUT

View file

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

View file

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

View file

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

View file

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

View file

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

View file

@ -1,4 +0,0 @@
[module-static-import-delayed.html]
[document.write in an imported module]
expected: FAIL

View file

@ -401,3 +401,6 @@
[X SNR (-384.8602297044423 dB) is not greater than or equal to 65.737. Got -384.8602297044423.]
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\]\t1.7380608709161053e-27\t9.3139332532882690e-1\t9.3139332532882690e-1\t1.0000000000000000e+0\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.3139332532882690e-1 at index of 28696.\n\tMax RelError of 1.0000000000000000e+0 at index of 28696.\n]
expected: FAIL

View file

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

View file

@ -24,6 +24,8 @@ test_computed_value("contain", "size layout");
test_computed_value("contain", "style paint");
test_computed_value("contain", "layout style paint");
test_computed_value("contain", "size layout style paint");
test_computed_value("contain", "size layout paint", "strict");
test_computed_value("contain", "layout paint", "content");
</script>
</body>
</html>

View file

@ -0,0 +1,22 @@
<!DOCTYPE html>
<title>SVG root as flex item</title>
<link rel="author" title="David Grogan" href="mailto:dgrogan@chromium.org">
<link rel="help" href="https://drafts.csswg.org/css-flexbox/#algo-main-item" title="Part E">
<link rel="help" href="https://crbug.com/965672">
<meta name="assert" content="When SVG has aspect ratio and no intrinsic height its flex-basis is available width * ratio, not 150px, when in a column flexbox." />
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="/resources/check-layout-th.js"></script>
The test passes if you see a 600x300 blue rectangle.
<div style="display: flex; flex-direction: column; width: 600px;">
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 200 100" data-expected-width=600 data-expected-height=300>
<rect x="0" y="0" width="200" height="100" fill="blue" />
</svg>
</div>
<script>
checkLayout('svg');
</script>

View file

@ -6,13 +6,13 @@
<script src=/common/get-host-info.sub.js></script>
<link rel="author" title="Noam Rosenthal" href="mailto:noam@webkit.org">
<link rel="help" href="https://github.com/w3c/csswg-drafts/issues/5165">
<link rel="match" href="reference/image-orientation-none-cross-origin-ref.html">
<link rel="match" href="reference/image-orientation-none-cross-origin-canvas-ref.html">
<meta name=fuzzy content="10;100">
<style>
img {display: none}
canvas {
width: 100px;
height: 100px;
width: 20px;
height: 20px;
margin: 10px;
}
</style>
@ -36,13 +36,13 @@
window.onload = () => {
const images = [
createImage({cors: true, src: src2, orientation: 'from-image', shouldBeRotated: true}),
createImage({cors: true, src: src2, orientation: 'none', shouldBeRotated: true}),
createImage({cors: false, src: src2, orientation: 'from-image', shouldBeRotated: true}),
createImage({cors: true, src: src1, orientation: 'from-image', shouldBeRotated: false}),
createImage({cors: true, src: src1, orientation: 'none', shouldBeRotated: false}),
createImage({cors: true, src: src2, orientation: 'from-image', shouldBeRotated: true}),
createImage({cors: true, src: src2, orientation: 'none', shouldBeRotated: true}),
createImage({cors: false, src: src1, orientation: 'from-image', shouldBeRotated: false}),
createImage({cors: false, src: src1, orientation: 'none', shouldBeRotated: false}),
createImage({cors: false, src: src2, orientation: 'from-image', shouldBeRotated: true}),
createImage({cors: false, src: src2, orientation: 'none', shouldBeRotated: false}),
]
@ -51,13 +51,16 @@
images.forEach(image => {
const canvas = document.createElement('canvas')
canvas.width = canvas.height = dimension
// The source of image-orientation preference for canvas drawImage
// is currently not standardized.
// See https://github.com/w3c/csswg-drafts/issues/4666
canvas.style.imageOrientation = image.style.imageOrientation
document.body.appendChild(canvas)
const ctx = canvas.getContext('2d')
const sx = image.dataset.shouldBeRotated === 'true' ? image.width * .8 : 0
const sy = image.dataset.shouldBeRotated === 'true' ? image.height * .8 : 0
ctx.drawImage(image, sx, sy, 1, 1, 0, 0, dimension, dimension)
document.body.appendChild(canvas)
})
}
</script>

View file

@ -13,11 +13,10 @@
}
img {display: none}
canvas {
width: 100px;
height: 100px;
width: 20px;
height: 20px;
margin: 10px;
}
.no-orient { image-orientation: none; }
</style>
<body>
<p>You should see 8 green rectangles, no red.</p>

View file

@ -0,0 +1,18 @@
<!DOCTYPE html>
<link rel="help" href="https://drafts.csswg.org/css-text-3/#white-space-property">
<link rel="author" title="Koji Ishii" href="mailto:kojii@chromium.org">
<style>
div {
width: 100px;
white-space: pre-wrap;
word-break: break-word;
border: 1px solid blue;
}
.atomic {
display: inline-block;
width: 99px;
height: 1em;
background: orange;
}
</style>
<div><span class="atomic"></span>&#x0D; <span class="atomic"></span></div>

View file

@ -0,0 +1,32 @@
// META: script=/resources/WebIDLParser.js
// META: script=/resources/idlharness.js
// https://drafts.fxtf.org/geometry/#DOMPoint
// https://drafts.fxtf.org/geometry/#DOMRect
// https://drafts.fxtf.org/geometry/#DOMQuad
// https://drafts.fxtf.org/geometry/#DOMMatrix
"use strict";
idl_test(
["geometry"],
[],
idlArray => {
const domRectListList = [];
if ("document" in self) {
domRectListList.push(document.getElementById('log').getClientRects());
}
idlArray.add_objects({
DOMPointReadOnly: ["new DOMPointReadOnly()"],
DOMPoint: ["new DOMPoint()"],
DOMRectReadOnly: ["new DOMRectReadOnly()"],
DOMRect: ["new DOMRect()"],
DOMRectList: domRectListList,
DOMQuad: ["new DOMQuad()"],
DOMMatrixReadOnly: ["new DOMMatrixReadOnly()", "DOMMatrixReadOnly.fromMatrix({is2D: false})"],
DOMMatrix: ["new DOMMatrix()", "DOMMatrix.fromMatrix({is2D: false})"]
});
idlArray.prevent_multiple_testing("DOMMatrixReadOnly");
idlArray.prevent_multiple_testing("DOMMatrix");
}
);

View file

@ -1,13 +0,0 @@
<!doctype html>
<meta charset=utf-8>
<title>Geometry APIs interface IDL tests</title>
<link rel=help href=https://drafts.fxtf.org/geometry/#DOMPoint>
<link rel=help href=https://drafts.fxtf.org/geometry/#DOMRect>
<link rel=help href=https://drafts.fxtf.org/geometry/#DOMQuad>
<link rel=help href=https://drafts.fxtf.org/geometry/#DOMMatrix>
<script src=/resources/testharness.js></script>
<script src=/resources/testharnessreport.js></script>
<script src=/resources/WebIDLParser.js></script>
<script src=/resources/idlharness.js></script>
<div id=log></div>
<script src=support/interfaces.js></script>

View file

@ -1,9 +0,0 @@
"use strict";
// https://drafts.fxtf.org/geometry/#DOMPoint
// https://drafts.fxtf.org/geometry/#DOMRect
// https://drafts.fxtf.org/geometry/#DOMQuad
// https://drafts.fxtf.org/geometry/#DOMMatrix
importScripts("/resources/testharness.js");
importScripts("/resources/WebIDLParser.js", "/resources/idlharness.js");
importScripts("support/interfaces.js");

View file

@ -1,31 +0,0 @@
"use strict";
var idlArray = new IdlArray();
const domRectListList = [];
if ("document" in self) {
domRectListList.push(document.getElementById('log').getClientRects());
}
function doTest(idl) {
idlArray.add_idls(idl);
idlArray.add_objects({
DOMPointReadOnly: ["new DOMPointReadOnly()"],
DOMPoint: ["new DOMPoint()"],
DOMRectReadOnly: ["new DOMRectReadOnly()"],
DOMRect: ["new DOMRect()"],
DOMRectList: domRectListList,
DOMQuad: ["new DOMQuad()"],
DOMMatrixReadOnly: ["new DOMMatrixReadOnly()", "DOMMatrixReadOnly.fromMatrix({is2D: false})"],
DOMMatrix: ["new DOMMatrix()", "DOMMatrix.fromMatrix({is2D: false})"],
});
idlArray.prevent_multiple_testing("DOMMatrixReadOnly");
idlArray.prevent_multiple_testing("DOMMatrix");
idlArray.test();
done();
}
promise_test(function() {
return fetch("/interfaces/geometry.idl").then(response => response.text())
.then(doTest);
}, "Test driver");

View file

@ -12,8 +12,16 @@
}, "iso-2022-jp encoder: " + desc)
}
encode("s", "s", "very basic")
encode("\u00A5\u203Es\\\uFF90\u4F69", "%1B(J\\~s%1B(B\\%1B$B%_PP%1B(B", "basics")
encode("\x0E\x0F\x1Bx", "%0E%0F%1Bx", "SO/SI ESC")
encode("s", "s", "very basic");
encode("\u00A5\u203Es\\\uFF90\u4F69", "%1B(J\\~s%1B(B\\%1B$B%_PP%1B(B", "basics");
encode("\uFF61", "%1B$B!%23%1B(B", "Katakana");
encode("\u0393", "%1B$B&%23%1B(B", "jis0208");
encode("\x0E\x0F\x1Bx", "%26%2365533%3B%26%2365533%3B%26%2365533%3Bx", "SO/SI ESC");
encode("\u203E\x0E\x0F\x1Bx", "%1B(J~%26%2365533%3B%26%2365533%3B%26%2365533%3Bx%1B(B", "Roman SO/SI ESC");
encode("\uFF61\x0E\x0F\x1Bx", "%1B$B!%23%1B(B%26%2365533%3B%26%2365533%3B%26%2365533%3Bx", "Katakana SO/SI ESC");
encode("\u0393\x0E\x0F\x1Bx", "%1B$B&%23%1B(B%26%2365533%3B%26%2365533%3B%26%2365533%3Bx", "jis0208 SO/SI ESC");
encode("\uFFFD", "%26%2365533%3B", "U+FFFD");
encode("\u203E\uFFFD", "%1B(J~%26%2365533%3B%1B(B", "Roman U+FFFD");
encode("\uFF61\uFFFD", "%1B$B!%23%1B(B%26%2365533%3B", "Katakana U+FFFD");
encode("\u0393\uFFFD", "%1B$B&%23%1B(B%26%2365533%3B", "jis0208 U+FFFD");
</script>

View file

@ -6,8 +6,6 @@
<script src="/resources/testdriver.js"></script>
<script src="/resources/testdriver-vendor.js"></script>
<iframe src="https://{{host}}:{{ports[https][1]}}/infrastructure/testdriver/click_child_testdriver.html"></iframe>
<script>
setup({single_test: true});
addEventListener("message", (msg) => {
@ -18,3 +16,8 @@ addEventListener("message", (msg) => {
}
});
</script>
<!-- Make sure we add the event listener before loading the iframe, to avoid
potentially missing messages from the child. -->
<iframe src="https://{{host}}:{{ports[https][1]}}/infrastructure/testdriver/click_child_testdriver.html"></iframe>

View file

@ -8,6 +8,13 @@
<script>
"use strict";
// Encodes |data| into a base64url string. There is no '=' padding, and the
// characters '-' and '_' must be used instead of '+' and '/', respectively.
function base64urlEncode(data) {
let result = btoa(data);
return result.replaceAll("=", "").replaceAll("+", "-").replaceAll("/", "_");
}
// The example attestation private key from the U2F spec at
// https://fidoalliance.org/specs/fido-u2f-v1.2-ps-20170411/fido-u2f-raw-message-formats-v1.2-ps-20170411.html#registration-example
// PKCS.8 encoded without encryption, as a base64url string.
@ -15,7 +22,7 @@ const private_key =
"MIGHAgEAMBMGByqGSM49AgEGCCqGSM49AwEHBG0wawIBAQQg8_zMDQDYAxlU-Q"
+ "hk1Dwkf0v18GZca1DMF3SaJ9HPdmShRANCAASNYX5lyVCOZLzFZzrIKmeZ2jwU"
+ "RmgsJYxGP__fWN_S-j5sN4tT15XEpN_7QZnt14YvI6uvAgO0uJEboFaZlOEB";
let credential_id = btoa("cred-1");
let credential_id = base64urlEncode("cred-1");
let credential = {
credentialId: credential_id,
rpId: window.location.hostname,
@ -58,7 +65,7 @@ promise_test(async t => {
promise_test(async t => {
let credential1 = credential;
let credential2 =
Object.assign({}, credential, {credentialId: btoa("cred-2")});
Object.assign({}, credential, {credentialId: base64urlEncode("cred-2")});
await test_driver.add_credential(authenticator_id, credential1);
await test_driver.add_credential(authenticator_id, credential2);

View file

@ -688,6 +688,7 @@ MISSING-LINK: css/cssom-view/scrollTop-display-change.html
# TODO https://github.com/web-platform-tests/wpt/issues/5770
MISSING-LINK: css/geometry/*.worker.js
MISSING-LINK: css/geometry/*.any.js
MISSING-LINK: css/filter-effects/*.any.js
# Tests that use WebKit/Blink testing APIs

View file

@ -0,0 +1,18 @@
importScripts("/resources/testharness.js");
test(t => {
// The Window test html conditionally fetches and runs these tests only if the
// implementation does not have a true-valued static
// canConstructInDedicatedWorker property on MediaSource in the Window
// context. So, the implementation must agree on lack of support here in the
// dedicated worker context.
// Ensure we're executing in a dedicated worker context.
assert_true(self instanceof DedicatedWorkerGlobalScope, "self instanceof DedicatedWorkerGlobalScope");
assert_true(self.MediaSource === undefined, "MediaSource is undefined in DedicatedWorker");
assert_throws_js(ReferenceError,
function() { var ms = new MediaSource(); },
"MediaSource construction in DedicatedWorker throws exception");
}, "MediaSource construction in DedicatedWorker context must fail if Window context did not claim MSE supported in DedicatedWorker");
done();

View file

@ -5,9 +5,13 @@
<script src="/resources/testharnessreport.js"></script>
<script>
async_test((t) => {
async_test(t => {
// Fail fast if MSE-in-Workers is not supported.
assert_true(MediaSource.hasOwnProperty("canConstructInDedicatedWorker"), "MediaSource hasOwnProperty 'canConstructInDedicatedWorker'");
assert_true(MediaSource.canConstructInDedicatedWorker, "MediaSource.canConstructInDedicatedWorker");
let worker = new Worker("mediasource-worker-util.js");
worker.onmessage = t.step_func((e) => {
worker.onmessage = t.step_func(e => {
if (e.data.substr(0,6) == "Error:") {
assert_unreached("Worker error: " + e.data);
} else {
@ -17,11 +21,18 @@ async_test((t) => {
t.done();
}
});
}, "Test main context revocation of worker MediaSource object URL");
}, "Test main context revocation of DedicatedWorker MediaSource object URL");
// Run some tests directly in another dedicated worker and get their results
// merged into those from this page.
fetch_tests_from_worker(new Worker("mediasource-worker-objecturl.js"));
if (MediaSource.hasOwnProperty("canConstructInDedicatedWorker") && MediaSource.canConstructInDedicatedWorker === true) {
// If implementation claims support for MSE-in-Workers, then fetch and run
// some tests directly in another dedicated worker and get their results
// merged into those from this page.
fetch_tests_from_worker(new Worker("mediasource-worker-objecturl.js"));
} else {
// Otherwise, fetch and run a test that verifies lack of support of
// MediaSource construction in another dedicated worker.
fetch_tests_from_worker(new Worker("mediasource-worker-must-fail-if-unsupported.js"));
}
</script>
</html>

View file

@ -1,23 +1,35 @@
importScripts("/resources/testharness.js");
test((t) => {
test(t => {
// The Window test html conditionally fetches and runs these tests only if the
// implementation exposes a true-valued static canConstructInDedicatedWorker
// attribute on MediaSource in the Window context. So, the implementation must
// agree on support here in the dedicated worker context.
// Ensure we're executing in a dedicated worker context.
assert_true(self instanceof DedicatedWorkerGlobalScope, "self instanceof DedicatedWorkerGlobalScope");
assert_true(MediaSource.hasOwnProperty("canConstructInDedicatedWorker", "DedicatedWorker MediaSource hasOwnProperty 'canConstructInDedicatedWorker'"));
assert_true(MediaSource.canConstructInDedicatedWorker, "DedicatedWorker MediaSource.canConstructInDedicatedWorker");
}, "MediaSource in DedicatedWorker context must have true-valued canConstructInDedicatedWorker if Window context had it");
test(t => {
const ms = new MediaSource();
assert_equals(ms.readyState, "closed");
}, "MediaSource construction succeeds with initial closed readyState in dedicated worker");
}, "MediaSource construction succeeds with initial closed readyState in DedicatedWorker");
test((t) => {
test(t => {
const ms = new MediaSource();
const url = URL.createObjectURL(ms);
assert_true(url != null);
assert_true(url.match(/^blob:.+/) != null);
}, "URL.createObjectURL(mediaSource) in dedicated worker returns a Blob URI");
}, "URL.createObjectURL(mediaSource) in DedicatedWorker returns a Blob URI");
test((t) => {
test(t => {
const ms = new MediaSource();
const url1 = URL.createObjectURL(ms);
const url2 = URL.createObjectURL(ms);
URL.revokeObjectURL(url1);
URL.revokeObjectURL(url2);
}, "URL.revokeObjectURL(mediaSource) in dedicated worker with two url for same MediaSource");
}, "URL.revokeObjectURL(mediaSource) in DedicatedWorker with two url for same MediaSource");
done();

View file

@ -18,13 +18,10 @@ function terminateWorkerAfterMultipleSetTimeouts(test, worker, timeouts_remainin
}
function startWorkerAndTerminateWorker(test, when_to_start_timeouts, timeouts_to_await) {
// TODO(https://crbug.com/878133): Enable main-thread feature detection of
// whether or not the implementation supports MSE-in-Workers, and fail the
// test rapidly here rather than flakily pass/failing the test on those
// implementations. If the timeout occurs near to when the worker's report
// of lack of MSE support reaches the main thread, then the test could
// pass in some cases (when timeout occurs prior to handling that error)
// and fail in others (when worker.onerror dispatch occurs first).
// Fail fast if MSE-in-Workers is not supported.
assert_true(MediaSource.hasOwnProperty("canConstructInDedicatedWorker"), "MediaSource hasOwnProperty 'canConstructInDedicatedWorker'");
assert_true(MediaSource.canConstructInDedicatedWorker, "MediaSource.canConstructInDedicatedWorker");
const worker = new Worker("mediasource-worker-util.js");
worker.onerror = test.unreached_func("worker error");
@ -46,7 +43,7 @@ function startWorkerAndTerminateWorker(test, when_to_start_timeouts, timeouts_to
terminateWorkerAfterMultipleSetTimeouts(test, worker, timeouts_to_await);
}
worker.onmessage = test.step_func((e) => {
worker.onmessage = test.step_func(e => {
if (e.data.substr(0,6) == "Error:") {
assert_unreached("Worker error: " + e.data);
} else {
@ -68,9 +65,9 @@ function startWorkerAndTerminateWorker(test, when_to_start_timeouts, timeouts_to
});
}
[ "before setting src", "after setting src", "after first ended event" ].forEach((when) => {
[ "before setting src", "after setting src", "after first ended event" ].forEach(when => {
for (let timeouts = 0; timeouts < 10; ++timeouts) {
async_test((test) => { startWorkerAndTerminateWorker(test, when, timeouts); },
async_test(test => { startWorkerAndTerminateWorker(test, when, timeouts); },
"Test worker MediaSource termination after at least " + timeouts +
" main thread setTimeouts, starting counting " + when);
}

View file

@ -6,15 +6,19 @@
<body>
<script>
async_test((t) => {
const video = document.createElement('video');
async_test(t => {
// Fail fast if MSE-in-Workers is not supported.
assert_true(MediaSource.hasOwnProperty("canConstructInDedicatedWorker"), "MediaSource hasOwnProperty 'canConstructInDedicatedWorker'");
assert_true(MediaSource.canConstructInDedicatedWorker, "MediaSource.canConstructInDedicatedWorker");
const video = document.createElement("video");
document.body.appendChild(video);
video.onerror = t.unreached_func("video element error");
video.onended = t.step_func_done();
let worker = new Worker("mediasource-worker-util.js");
worker.onerror = t.unreached_func("worker error");
worker.onmessage = t.step_func((e) => {
worker.onmessage = t.step_func(e => {
if (e.data.substr(0,6) == "Error:") {
assert_unreached("Worker error: " + e.data);
} else {

View file

@ -33,8 +33,8 @@ function loadBinaryAsync(url) {
return new Promise((resolve, reject) => {
let request = new XMLHttpRequest();
request.open("GET", url, true);
request.responseType = 'arraybuffer';
request.onerror = (event) => { reject(event); };
request.responseType = "arraybuffer";
request.onerror = event => { reject(event); };
request.onload = () => {
if (request.status != 200) {
reject("Unexpected loadData_ status code : " + request.status);
@ -76,6 +76,6 @@ mediaSource.addEventListener("sourceopen", () => {
mediaSource.endOfStream();
};
};
mediaLoad.then( (mediaData) => { sourceBuffer.appendBuffer(mediaData); },
(err) => { postMessage("Error: " + err) } );
mediaLoad.then( mediaData => { sourceBuffer.appendBuffer(mediaData); },
err => { postMessage("Error: " + err) } );
}, { once : true });

View file

@ -16,6 +16,7 @@
test(()=>assert_true(true, '2'));
test(() => assert_true(true, '3'));
test(() => assert_true(true, '3')); // test duplicate behaviour
test(() => assert_true(true, '3')); // test duplicate behaviour
test(() => {
assert_true(true, '4');
});
@ -62,6 +63,12 @@
"properties": {},
"message": null
},
{
"status_string": "PASS",
"name": "assert_true(true, '3') 2",
"properties": {},
"message": null
},
{
"status_string": "PASS",
"name": "Tests with no title 1",

View file

@ -541,14 +541,15 @@ policies and contribution forms [3].
trimmed = trimmed.replace(/^([^;]*)(;\s*)+$/, "$1");
if (trimmed) {
// add a suffix if we already have this string
let name = trimmed;
if (seen_func_name[trimmed]) {
trimmed = trimmed + " " + seen_func_name[trimmed];
seen_func_name[trimmed]++;
// This subtest name already exists, so add a suffix.
name += " " + seen_func_name[trimmed];
} else {
seen_func_name[trimmed] = 1;
seen_func_name[trimmed] = 0;
}
return trimmed;
seen_func_name[trimmed] += 1;
return name;
}
}
}

View file

@ -0,0 +1,41 @@
<!DOCTYPE html>
<title>Service Worker: Static imports from module top-level scripts shouldn't be affected by the service worker script path restriction</title>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="resources/test-helpers.sub.js"></script>
<script>
// https://w3c.github.io/ServiceWorker/#path-restriction
// is applied to top-level scripts in
// https://w3c.github.io/ServiceWorker/#update-algorithm
// but not to submodules imported from top-level scripts.
async function runTest(t, script, scope) {
const script_url = new URL(script, location.href);
await service_worker_unregister(t, scope);
const registration = await
navigator.serviceWorker.register(script, {type: 'module'});
t.add_cleanup(_ => registration.unregister());
const msg = await new Promise(resolve => {
registration.installing.postMessage('ping');
navigator.serviceWorker.onmessage = resolve;
});
assert_equals(msg.data, 'pong');
}
promise_test(async t => {
await runTest(t,
'resources/scope2/imported-module-script.js',
'resources/scope2/');
}, 'imported-module-script.js works when used as top-level');
promise_test(async t => {
await runTest(t,
'resources/scope1/module-worker-importing-scope2.js',
'resources/scope1/');
}, 'static imports to outside path restriction should be allowed');
promise_test(async t => {
await runTest(t,
'resources/scope1/module-worker-importing-redirect-to-scope2.js',
'resources/scope1/');
}, 'static imports redirecting to outside path restriction should be allowed');
</script>

View file

@ -0,0 +1 @@
import * as module from './redirect.py?Redirect=/service-workers/service-worker/resources/scope2/imported-module-script.js';

View file

@ -0,0 +1 @@
import * as module from '../scope2/imported-module-script.js';

View file

@ -0,0 +1,4 @@
export const imported = 'A module script.';
onmessage = msg => {
msg.source.postMessage('pong');
};

View file

@ -1,6 +1,5 @@
import errno
import os
import platform
import shutil
import socket
import subprocess
@ -44,9 +43,6 @@ def get_persistent_manifest_path():
@pytest.fixture(scope="module", autouse=True)
def init_manifest():
# See https://github.com/pypa/virtualenv/issues/1710
if sys.version_info[0] >= 3 and platform.system() == "Windows":
pytest.xfail(reason="virtualenv activation fails in Windows for python3")
with pytest.raises(SystemExit) as excinfo:
wpt.main(argv=["manifest", "--no-download",
"--path", get_persistent_manifest_path()])

View file

@ -86,7 +86,7 @@ class TestUsingServer(unittest.TestCase):
assert resp.info()[name] == ", ".join(values)
@pytest.mark.skipif(not wptserve.utils.http2_compatible(), reason="h2 server only works in python 2.7.15")
@pytest.mark.skipif(not wptserve.utils.http2_compatible(), reason="h2 server only works in python 2.7.10+ and Python 3.6+")
class TestUsingH2Server:
def setup_method(self, test_method):
self.server = wptserve.server.WebTestHttpd(host="localhost",

View file

@ -9,6 +9,11 @@ def get_events(session):
key = e["key"]
hex_suffix = key[key.index("+") + 1:]
e["key"] = unichr(int(hex_suffix, 16))
# WebKit sets code as 'Unidentified' for unidentified key codes, but
# tests expect ''.
if "code" in e and e["code"] == "Unidentified":
e["code"] = ""
return events