mirror of
https://github.com/servo/servo.git
synced 2025-08-05 13:40:08 +01:00
Update web-platform-tests to revision 3c2377fc1d3a0fc5da425dc5e63bbedab8cd3d9e
This commit is contained in:
parent
b52ddc5290
commit
c0949024fc
33 changed files with 791 additions and 98 deletions
|
@ -7,7 +7,7 @@
|
|||
expected: FAIL
|
||||
|
||||
[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.]
|
||||
expected: FAIL
|
||||
|
|
|
@ -266192,6 +266192,9 @@
|
|||
"css/support/b-green.css": [
|
||||
[]
|
||||
],
|
||||
"css/support/blue-100.png": [
|
||||
[]
|
||||
],
|
||||
"css/support/blue32x32.ico": [
|
||||
[]
|
||||
],
|
||||
|
@ -269432,6 +269435,9 @@
|
|||
"dom/events/resources/event-global-extra-frame.html": [
|
||||
[]
|
||||
],
|
||||
"dom/events/resources/prefixed-animation-event-tests.js": [
|
||||
[]
|
||||
],
|
||||
"dom/events/scrolling/scroll_support.js": [
|
||||
[]
|
||||
],
|
||||
|
@ -325563,6 +325569,12 @@
|
|||
{}
|
||||
]
|
||||
],
|
||||
"css/css-grid/alignment/grid-align-stretching-replaced-items.html": [
|
||||
[
|
||||
"css/css-grid/alignment/grid-align-stretching-replaced-items.html",
|
||||
{}
|
||||
]
|
||||
],
|
||||
"css/css-grid/alignment/grid-align.html": [
|
||||
[
|
||||
"css/css-grid/alignment/grid-align.html",
|
||||
|
@ -341968,6 +341980,30 @@
|
|||
{}
|
||||
]
|
||||
],
|
||||
"dom/events/webkit-animation-end-event.html": [
|
||||
[
|
||||
"dom/events/webkit-animation-end-event.html",
|
||||
{}
|
||||
]
|
||||
],
|
||||
"dom/events/webkit-animation-iteration-event.html": [
|
||||
[
|
||||
"dom/events/webkit-animation-iteration-event.html",
|
||||
{}
|
||||
]
|
||||
],
|
||||
"dom/events/webkit-animation-start-event.html": [
|
||||
[
|
||||
"dom/events/webkit-animation-start-event.html",
|
||||
{}
|
||||
]
|
||||
],
|
||||
"dom/events/webkit-transition-end-event.html": [
|
||||
[
|
||||
"dom/events/webkit-transition-end-event.html",
|
||||
{}
|
||||
]
|
||||
],
|
||||
"dom/historical.html": [
|
||||
[
|
||||
"dom/historical.html",
|
||||
|
@ -582948,6 +582984,10 @@
|
|||
"9feeed3e0ef2a17b68bce2b7d71cbdb14a06ee2d",
|
||||
"testharness"
|
||||
],
|
||||
"css/css-grid/alignment/grid-align-stretching-replaced-items.html": [
|
||||
"f9b455d4c163af1ffd6cf03a7361316ce1a21246",
|
||||
"testharness"
|
||||
],
|
||||
"css/css-grid/alignment/grid-align.html": [
|
||||
"a195945d1f97f0f4befc7a8d86a6291a2e1bab34",
|
||||
"testharness"
|
||||
|
@ -631548,6 +631588,10 @@
|
|||
"a0473f5ca26652c1229290bbf1f81eabc1e37280",
|
||||
"support"
|
||||
],
|
||||
"css/support/blue-100.png": [
|
||||
"f578ae72533c7746c8a4d2f6eef32a8137ee1f4b",
|
||||
"support"
|
||||
],
|
||||
"css/support/blue32x32.ico": [
|
||||
"5844dd614c22028ce81422233c0aa400a6f41e0d",
|
||||
"support"
|
||||
|
@ -641205,7 +641249,7 @@
|
|||
"testharness"
|
||||
],
|
||||
"custom-elements/form-associated/ElementInternals-accessibility.html": [
|
||||
"c98d771b502ea346e4131569c836282fbfa54d58",
|
||||
"b07320bb879820bfde477937f359d1e1132ac74d",
|
||||
"testharness"
|
||||
],
|
||||
"custom-elements/form-associated/ElementInternals-labels.html": [
|
||||
|
@ -642196,6 +642240,10 @@
|
|||
"241dda8b66f8c8fe128e736bcb073479aee634a9",
|
||||
"support"
|
||||
],
|
||||
"dom/events/resources/prefixed-animation-event-tests.js": [
|
||||
"021b6bb9dfdc422d1a6c3c9c4a1a039f89a901d5",
|
||||
"support"
|
||||
],
|
||||
"dom/events/scrolling/overscroll-event-fired-to-document.html": [
|
||||
"c054ffca9c471f78ce5d1cbaa210fa7aad3aee3b",
|
||||
"testharness"
|
||||
|
@ -642240,6 +642288,22 @@
|
|||
"713555b7d8ab6117d12c70d08185335246e44e1a",
|
||||
"testharness"
|
||||
],
|
||||
"dom/events/webkit-animation-end-event.html": [
|
||||
"4186f6b7a9d2415f7df6174b7b5ea9e42c550bae",
|
||||
"testharness"
|
||||
],
|
||||
"dom/events/webkit-animation-iteration-event.html": [
|
||||
"e6e7ec1459036870424300541612cdf48bb7f8dd",
|
||||
"testharness"
|
||||
],
|
||||
"dom/events/webkit-animation-start-event.html": [
|
||||
"ad1036644a96e15956d5159b886ca7879a916204",
|
||||
"testharness"
|
||||
],
|
||||
"dom/events/webkit-transition-end-event.html": [
|
||||
"2741824e3054a2b4fa41d0cfe33488e7a3cdd3ae",
|
||||
"testharness"
|
||||
],
|
||||
"dom/historical.html": [
|
||||
"8a71e364e5ef30a0f9d9621d3eb018a34d42ae4c",
|
||||
"testharness"
|
||||
|
@ -643189,7 +643253,7 @@
|
|||
"testharness"
|
||||
],
|
||||
"dom/nodes/aria-element-reflection.tentative.html": [
|
||||
"b4e22f0cc6ad4ece0409430bcdc21de737a5cf09",
|
||||
"9073e52075a502943cf9dfb7586174e0533b63fa",
|
||||
"testharness"
|
||||
],
|
||||
"dom/nodes/attributes.html": [
|
||||
|
@ -673785,7 +673849,7 @@
|
|||
"support"
|
||||
],
|
||||
"interfaces/wai-aria.idl": [
|
||||
"c4fbf11409cf142d8295038d256f5a686d860a55",
|
||||
"9cae4025d822dcaff47dd25b66dafa3c49a29c09",
|
||||
"support"
|
||||
],
|
||||
"interfaces/wake-lock.idl": [
|
||||
|
@ -702701,7 +702765,7 @@
|
|||
"support"
|
||||
],
|
||||
"resources/chromium/nfc-mock.js": [
|
||||
"be86dedd4d8877dcb01ade039c95cbb8f7acc99f",
|
||||
"84c2726e09b335c12ada7cc922d8acefa21ae805",
|
||||
"support"
|
||||
],
|
||||
"resources/chromium/sensor.mojom.js": [
|
||||
|
@ -725833,7 +725897,7 @@
|
|||
"testharness"
|
||||
],
|
||||
"web-nfc/NDEFRecord_constructor.https.html": [
|
||||
"0e0f1a771394570747117980c824c133ca3b060d",
|
||||
"ef38a27a0506dfbef88edc16aa13797af64438d1",
|
||||
"testharness"
|
||||
],
|
||||
"web-nfc/NDEFWriter-document-hidden-manual.https.html": [
|
||||
|
@ -725841,7 +725905,7 @@
|
|||
"manual"
|
||||
],
|
||||
"web-nfc/NDEFWriter_push.https.html": [
|
||||
"bf7c1f86ad0b4fdf066b4bc4584f9409d840d823",
|
||||
"33a629781ed7a7c94671b2cfacda50975cde9d61",
|
||||
"testharness"
|
||||
],
|
||||
"web-nfc/README.md": [
|
||||
|
@ -725857,7 +725921,7 @@
|
|||
"testharness"
|
||||
],
|
||||
"web-nfc/resources/nfc-helpers.js": [
|
||||
"b9e260ac71403a8e30422b4f8d1d63c40d3d00c4",
|
||||
"45bfa6deced49dd3eb4c38cc5856f123ed1f91b2",
|
||||
"support"
|
||||
],
|
||||
"web-nfc/resources/support-iframe.html": [
|
||||
|
@ -729401,7 +729465,7 @@
|
|||
"testharness"
|
||||
],
|
||||
"webrtc/RTCRtpTransceiver.https.html": [
|
||||
"af84fe2498c9242f49639fa1bd55a4e848affbbf",
|
||||
"67571895175f19c008743523f035aa31fced9681",
|
||||
"testharness"
|
||||
],
|
||||
"webrtc/RTCSctpTransport-constructor.html": [
|
||||
|
|
|
@ -2,6 +2,3 @@
|
|||
[listeners are called when <iframe> is resized]
|
||||
expected: FAIL
|
||||
|
||||
[listeners are called correct number of times]
|
||||
expected: FAIL
|
||||
|
||||
|
|
|
@ -2,3 +2,6 @@
|
|||
[elementsFromPoint on the root document for points in iframe elements]
|
||||
expected: FAIL
|
||||
|
||||
[elementsFromPoint on inner documents]
|
||||
expected: FAIL
|
||||
|
||||
|
|
|
@ -0,0 +1,40 @@
|
|||
[webkit-animation-end-event.html]
|
||||
[event types for prefixed and unprefixed animationend event handlers should be named appropriately]
|
||||
expected: FAIL
|
||||
|
||||
[onwebkitanimationend event handler should not trigger if an unprefixed listener also exists]
|
||||
expected: FAIL
|
||||
|
||||
[webkitAnimationEnd event listener should not trigger if an unprefixed event handler also exists]
|
||||
expected: FAIL
|
||||
|
||||
[webkitAnimationEnd event listener is case sensitive]
|
||||
expected: FAIL
|
||||
|
||||
[webkitAnimationEnd event listener should trigger for an animation]
|
||||
expected: FAIL
|
||||
|
||||
[onwebkitanimationend event handler should trigger for an animation]
|
||||
expected: FAIL
|
||||
|
||||
[onanimationend and onwebkitanimationend are not aliases]
|
||||
expected: FAIL
|
||||
|
||||
[dispatchEvent of a webkitAnimationEnd event does not trigger an unprefixed event handler or listener]
|
||||
expected: FAIL
|
||||
|
||||
[dispatchEvent of a webkitAnimationEnd event does trigger a prefixed event handler or listener]
|
||||
expected: FAIL
|
||||
|
||||
[webkitAnimationEnd event listener should not trigger if an unprefixed listener also exists]
|
||||
expected: FAIL
|
||||
|
||||
[dispatchEvent of an animationend event does not trigger a prefixed event handler or listener]
|
||||
expected: FAIL
|
||||
|
||||
[event types for prefixed and unprefixed animationend event listeners should be named appropriately]
|
||||
expected: FAIL
|
||||
|
||||
[onwebkitanimationend event handler should not trigger if an unprefixed event handler also exists]
|
||||
expected: FAIL
|
||||
|
|
@ -0,0 +1,40 @@
|
|||
[webkit-animation-iteration-event.html]
|
||||
[webkitAnimationIteration event listener is case sensitive]
|
||||
expected: FAIL
|
||||
|
||||
[dispatchEvent of a webkitAnimationIteration event does not trigger an unprefixed event handler or listener]
|
||||
expected: FAIL
|
||||
|
||||
[onwebkitanimationiteration event handler should trigger for an animation]
|
||||
expected: FAIL
|
||||
|
||||
[dispatchEvent of a webkitAnimationIteration event does trigger a prefixed event handler or listener]
|
||||
expected: FAIL
|
||||
|
||||
[webkitAnimationIteration event listener should trigger for an animation]
|
||||
expected: FAIL
|
||||
|
||||
[webkitAnimationIteration event listener should not trigger if an unprefixed listener also exists]
|
||||
expected: FAIL
|
||||
|
||||
[onwebkitanimationiteration event handler should not trigger if an unprefixed event handler also exists]
|
||||
expected: FAIL
|
||||
|
||||
[event types for prefixed and unprefixed animationiteration event handlers should be named appropriately]
|
||||
expected: FAIL
|
||||
|
||||
[event types for prefixed and unprefixed animationiteration event listeners should be named appropriately]
|
||||
expected: FAIL
|
||||
|
||||
[webkitAnimationIteration event listener should not trigger if an unprefixed event handler also exists]
|
||||
expected: FAIL
|
||||
|
||||
[onanimationiteration and onwebkitanimationiteration are not aliases]
|
||||
expected: FAIL
|
||||
|
||||
[dispatchEvent of an animationiteration event does not trigger a prefixed event handler or listener]
|
||||
expected: FAIL
|
||||
|
||||
[onwebkitanimationiteration event handler should not trigger if an unprefixed listener also exists]
|
||||
expected: FAIL
|
||||
|
|
@ -0,0 +1,40 @@
|
|||
[webkit-animation-start-event.html]
|
||||
[webkitAnimationStart event listener should not trigger if an unprefixed event handler also exists]
|
||||
expected: FAIL
|
||||
|
||||
[webkitAnimationStart event listener should trigger for an animation]
|
||||
expected: FAIL
|
||||
|
||||
[event types for prefixed and unprefixed animationstart event handlers should be named appropriately]
|
||||
expected: FAIL
|
||||
|
||||
[event types for prefixed and unprefixed animationstart event listeners should be named appropriately]
|
||||
expected: FAIL
|
||||
|
||||
[dispatchEvent of an animationstart event does not trigger a prefixed event handler or listener]
|
||||
expected: FAIL
|
||||
|
||||
[onwebkitanimationstart event handler should trigger for an animation]
|
||||
expected: FAIL
|
||||
|
||||
[onanimationstart and onwebkitanimationstart are not aliases]
|
||||
expected: FAIL
|
||||
|
||||
[onwebkitanimationstart event handler should not trigger if an unprefixed event handler also exists]
|
||||
expected: FAIL
|
||||
|
||||
[onwebkitanimationstart event handler should not trigger if an unprefixed listener also exists]
|
||||
expected: FAIL
|
||||
|
||||
[dispatchEvent of a webkitAnimationStart event does trigger a prefixed event handler or listener]
|
||||
expected: FAIL
|
||||
|
||||
[dispatchEvent of a webkitAnimationStart event does not trigger an unprefixed event handler or listener]
|
||||
expected: FAIL
|
||||
|
||||
[webkitAnimationStart event listener should not trigger if an unprefixed listener also exists]
|
||||
expected: FAIL
|
||||
|
||||
[webkitAnimationStart event listener is case sensitive]
|
||||
expected: FAIL
|
||||
|
|
@ -0,0 +1,31 @@
|
|||
[webkit-transition-end-event.html]
|
||||
[dispatchEvent of a webkitTransitionEnd event does not trigger an unprefixed event handler or listener]
|
||||
expected: FAIL
|
||||
|
||||
[dispatchEvent of an transitionend event does not trigger a prefixed event handler or listener]
|
||||
expected: FAIL
|
||||
|
||||
[onwebkittransitionend event handler should trigger for an animation]
|
||||
expected: FAIL
|
||||
|
||||
[onwebkittransitionend event handler should not trigger if an unprefixed listener also exists]
|
||||
expected: FAIL
|
||||
|
||||
[event types for prefixed and unprefixed transitionend event handlers should be named appropriately]
|
||||
expected: FAIL
|
||||
|
||||
[event types for prefixed and unprefixed transitionend event listeners should be named appropriately]
|
||||
expected: FAIL
|
||||
|
||||
[ontransitionend and onwebkittransitionend are not aliases]
|
||||
expected: FAIL
|
||||
|
||||
[webkitTransitionEnd event listener should trigger for an animation]
|
||||
expected: FAIL
|
||||
|
||||
[dispatchEvent of a webkitTransitionEnd event does trigger a prefixed event handler or listener]
|
||||
expected: FAIL
|
||||
|
||||
[onwebkittransitionend event handler should not trigger if an unprefixed event handler also exists]
|
||||
expected: FAIL
|
||||
|
|
@ -315,18 +315,18 @@
|
|||
[<iframe>: combined response Content-Type: text/html;" \\" text/plain]
|
||||
expected: FAIL
|
||||
|
||||
[<iframe>: combined response Content-Type: text/html;" text/plain]
|
||||
[<iframe>: separate response Content-Type: text/plain */*]
|
||||
expected: FAIL
|
||||
|
||||
[<iframe>: combined response Content-Type: */* text/html]
|
||||
[<iframe>: combined response Content-Type: text/html */*;charset=gbk]
|
||||
expected: FAIL
|
||||
|
||||
[<iframe>: separate response Content-Type: text/html;" text/plain]
|
||||
[<iframe>: separate response Content-Type: text/html;x=" text/plain]
|
||||
expected: FAIL
|
||||
|
||||
[<iframe>: separate response Content-Type: text/html */*;charset=gbk]
|
||||
[<iframe>: separate response Content-Type: text/html;" \\" text/plain]
|
||||
expected: FAIL
|
||||
|
||||
[<iframe>: separate response Content-Type: text/html */*]
|
||||
[<iframe>: separate response Content-Type: text/plain */*;charset=gbk]
|
||||
expected: FAIL
|
||||
|
||||
|
|
|
@ -53,6 +53,3 @@
|
|||
[combined text/javascript ]
|
||||
expected: FAIL
|
||||
|
||||
[separate text/javascript x/x]
|
||||
expected: FAIL
|
||||
|
||||
|
|
|
@ -11,6 +11,9 @@
|
|||
[X-Content-Type-Options%3A%20nosniff%0C]
|
||||
expected: FAIL
|
||||
|
||||
[X-Content-Type-Options%3A%20'NosniFF']
|
||||
[X-Content-Type-Options%3A%20%40%23%24%23%25%25%26%5E%26%5E*()()11!%2Cnosniff]
|
||||
expected: FAIL
|
||||
|
||||
[X-Content-Type-Options%3A%20%2Cnosniff]
|
||||
expected: FAIL
|
||||
|
||||
|
|
|
@ -1,4 +0,0 @@
|
|||
[traverse_the_history_1.html]
|
||||
[Multiple history traversals from the same task]
|
||||
expected: FAIL
|
||||
|
|
@ -1,4 +0,0 @@
|
|||
[traverse_the_history_2.html]
|
||||
[Multiple history traversals, last would be aborted]
|
||||
expected: FAIL
|
||||
|
|
@ -1,5 +1,4 @@
|
|||
[creating_browsing_context_test_01.html]
|
||||
expected: TIMEOUT
|
||||
[first argument: absolute url]
|
||||
expected: TIMEOUT
|
||||
expected: FAIL
|
||||
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
expected: FAIL
|
||||
|
||||
[Element with tabindex should support autofocus]
|
||||
expected: FAIL
|
||||
expected: TIMEOUT
|
||||
|
||||
[Host element with delegatesFocus including no focusable descendants should be skipped]
|
||||
expected: NOTRUN
|
||||
|
@ -16,5 +16,5 @@
|
|||
expected: NOTRUN
|
||||
|
||||
[Non-HTMLElement should not support autofocus]
|
||||
expected: TIMEOUT
|
||||
expected: NOTRUN
|
||||
|
||||
|
|
|
@ -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
|
||||
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
[crossorigin-sandwich-TAO.sub.html]
|
||||
expected: ERROR
|
||||
[There should be one entry.]
|
||||
expected: FAIL
|
||||
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
[005.html]
|
||||
expected: ERROR
|
||||
[dedicated worker in shared worker in dedicated worker]
|
||||
expected: FAIL
|
||||
|
||||
|
|
|
@ -0,0 +1,78 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>CSS Grid Layout Test: alignment for replaced element</title>
|
||||
<link rel="author" title="Rossana Monteriso" href="mailto:rmonteriso@igalia.com">
|
||||
<link rel="help" href="https://drafts.csswg.org/css-align-3/#propdef-align-self">
|
||||
<link rel="help" href="https://drafts.csswg.org/css-align-3/#propdef-justify-self">
|
||||
<link rel="help" href="https://developer.mozilla.org/en-US/docs/Web/CSS/Replaced_element">
|
||||
<link rel="help" href="https://drafts.csswg.org/css-align/#align-grid">
|
||||
<link rel="help" href="https://www.w3.org/TR/css-grid-1/#grid-item-sizing">
|
||||
<meta name="assert" content="This test checks that the alignment properties apply the 'stretch' value correctly on replaced elements, such as images.">
|
||||
<meta name="flags" content="ahem">
|
||||
<link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
|
||||
<link rel="stylesheet" href="/css/support/grid.css">
|
||||
<link rel="stylesheet" href="/css/support/alignment.css">
|
||||
|
||||
<style>
|
||||
.grid {
|
||||
grid-template-columns: 500px;
|
||||
grid-template-rows: 500px;
|
||||
}
|
||||
.fixedSizes {
|
||||
width: 150px;
|
||||
height: 150px;
|
||||
}
|
||||
.autoMargins {
|
||||
margin: auto;
|
||||
}
|
||||
</style>
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
<script src="/resources/check-layout-th.js"></script>
|
||||
|
||||
<body onload="checkLayout('.grid')">
|
||||
|
||||
<p>This test checks that the alignment properties align-self and justify-self apply the 'stretch' value correctly on replaced elements.</p>
|
||||
|
||||
<div style="position: relative">
|
||||
<p>The green image's original size is 100px x 100px, default alignment is resolved as 'start' for replaced elements so it prevents stretching to be applied.</p>
|
||||
<div class="grid">
|
||||
<img src="/css/support/blue-100.png" data-expected-width="100" data-expected-height="100"/>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div style="position: relative">
|
||||
<p>The green image's original size is 100px x 100px, 'normal' is resolved as 'start' for replaced elements so it prevents stretching to be applied.</p>
|
||||
<div class="grid itemsNormal">
|
||||
<img src="/css/support/blue-100.png" data-expected-width="100" data-expected-height="100"/>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div style="position: relative">
|
||||
<p>The green image's original size is 100px x 100px, but it should be stretched to fill the 500px x 500px grid area it's placed into.</p>
|
||||
<div class="grid alignItemsStretch justifyItemsStretch">
|
||||
<img src="/css/support/blue-100.png" data-expected-width="500" data-expected-height="500"/>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div style="position: relative">
|
||||
<p>The green image's original size is 100px x 100px, non-stretch values prevent stretching to be applied.</p>
|
||||
<div class="grid itemsCenter">
|
||||
<img src="/css/support/blue-100.png" data-expected-width="100" data-expected-height="100"/>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div style="position: relative">
|
||||
<p>The green image's original size is 100px x 100px, non-auto sizes prevent stretching to be applied.</p>
|
||||
<div class="grid">
|
||||
<img class="fixedSizes" src="/css/support/blue-100.png" data-expected-width="150" data-expected-height="150"/>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div style="position: relative">
|
||||
<p>The green image's original size is 100px x 100px, auto-margins prevent stretching to be applied.</p>
|
||||
<div class="grid">
|
||||
<img class="autoMargins" src="/css/support/blue-100.png" data-expected-width="100" data-expected-height="100"/>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
BIN
tests/wpt/web-platform-tests/css/support/blue-100.png
Normal file
BIN
tests/wpt/web-platform-tests/css/support/blue-100.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 92 B |
|
@ -36,7 +36,7 @@ const properties = [
|
|||
"ariaControlsElements",
|
||||
"ariaCurrent",
|
||||
"ariaDescribedByElements",
|
||||
"ariaDetailsElement",
|
||||
"ariaDetailsElements",
|
||||
"ariaDisabled",
|
||||
"ariaErrorMessageElement",
|
||||
"ariaExpanded",
|
||||
|
|
|
@ -0,0 +1,366 @@
|
|||
'use strict'
|
||||
|
||||
// Runs a set of tests for a given prefixed/unprefixed animation event (e.g.
|
||||
// animationstart/webkitAnimationStart).
|
||||
//
|
||||
// The eventDetails object must have the following form:
|
||||
// {
|
||||
// isTransition: false, <-- can be omitted, default false
|
||||
// unprefixedType: 'animationstart',
|
||||
// prefixedType: 'webkitAnimationStart',
|
||||
// animationCssStyle: '1ms', <-- must NOT include animation name or
|
||||
// transition property
|
||||
// }
|
||||
function runAnimationEventTests(eventDetails) {
|
||||
const {
|
||||
isTransition,
|
||||
unprefixedType,
|
||||
prefixedType,
|
||||
animationCssStyle
|
||||
} = eventDetails;
|
||||
|
||||
// Derive the DOM event handler names, e.g. onanimationstart.
|
||||
const unprefixedHandler = `on${unprefixedType}`;
|
||||
const prefixedHandler = `on${prefixedType.toLowerCase()}`;
|
||||
|
||||
const style = document.createElement('style');
|
||||
document.head.appendChild(style);
|
||||
if (isTransition) {
|
||||
style.sheet.insertRule(
|
||||
`.baseStyle { width: 100px; transition: width ${animationCssStyle}; }`);
|
||||
style.sheet.insertRule('.transition { width: 200px !important; }');
|
||||
} else {
|
||||
style.sheet.insertRule('@keyframes anim {}');
|
||||
}
|
||||
|
||||
function triggerAnimation(div) {
|
||||
if (isTransition) {
|
||||
div.classList.add('transition');
|
||||
} else {
|
||||
div.style.animation = `anim ${animationCssStyle}`;
|
||||
}
|
||||
}
|
||||
|
||||
test(t => {
|
||||
const div = createDiv(t);
|
||||
|
||||
assert_equals(div[unprefixedHandler], null,
|
||||
`${unprefixedHandler} should initially be null`);
|
||||
assert_equals(div[prefixedHandler], null,
|
||||
`${prefixedHandler} should initially be null`);
|
||||
|
||||
// Setting one should not affect the other.
|
||||
div[unprefixedHandler] = () => { };
|
||||
|
||||
assert_not_equals(div[unprefixedHandler], null,
|
||||
`setting ${unprefixedHandler} should make it non-null`);
|
||||
assert_equals(div[prefixedHandler], null,
|
||||
`setting ${unprefixedHandler} should not affect ${prefixedHandler}`);
|
||||
|
||||
div[prefixedHandler] = () => { };
|
||||
|
||||
assert_not_equals(div[prefixedHandler], null,
|
||||
`setting ${prefixedHandler} should make it non-null`);
|
||||
assert_not_equals(div[unprefixedHandler], div[prefixedHandler],
|
||||
'the setters should be different');
|
||||
}, `${unprefixedHandler} and ${prefixedHandler} are not aliases`);
|
||||
|
||||
// The below tests primarily test the interactions of prefixed animation
|
||||
// events in the algorithm for invoking events:
|
||||
// https://dom.spec.whatwg.org/#concept-event-listener-invoke
|
||||
|
||||
promise_test(async t => {
|
||||
const div = createDiv(t);
|
||||
|
||||
let receivedEventCount = 0;
|
||||
addTestScopedEventHandler(t, div, prefixedHandler, () => {
|
||||
receivedEventCount++;
|
||||
});
|
||||
addTestScopedEventListener(t, div, prefixedType, () => {
|
||||
receivedEventCount++;
|
||||
});
|
||||
|
||||
// The HTML spec[0] specifies that the prefixed event handlers have an
|
||||
// 'Event handler event type' of the appropriate prefixed event type. E.g.
|
||||
// onwebkitanimationend creates a listener for the event type
|
||||
// 'webkitAnimationEnd'.
|
||||
//
|
||||
// [0]: https://html.spec.whatwg.org/multipage/webappapis.html#event-handlers-on-elements,-document-objects,-and-window-objects
|
||||
div.dispatchEvent(new AnimationEvent(prefixedType));
|
||||
assert_equals(receivedEventCount, 2,
|
||||
'prefixed listener and handler received event');
|
||||
}, `dispatchEvent of a ${prefixedType} event does trigger a ` +
|
||||
`prefixed event handler or listener`);
|
||||
|
||||
promise_test(async t => {
|
||||
const div = createDiv(t);
|
||||
|
||||
let receivedEvent = false;
|
||||
addTestScopedEventHandler(t, div, unprefixedHandler, () => {
|
||||
receivedEvent = true;
|
||||
});
|
||||
addTestScopedEventListener(t, div, unprefixedType, () => {
|
||||
receivedEvent = true;
|
||||
});
|
||||
|
||||
div.dispatchEvent(new AnimationEvent(prefixedType));
|
||||
assert_false(receivedEvent,
|
||||
'prefixed listener or handler received event');
|
||||
}, `dispatchEvent of a ${prefixedType} event does not trigger an ` +
|
||||
`unprefixed event handler or listener`);
|
||||
|
||||
|
||||
promise_test(async t => {
|
||||
const div = createDiv(t);
|
||||
|
||||
let receivedEvent = false;
|
||||
addTestScopedEventHandler(t, div, prefixedHandler, () => {
|
||||
receivedEvent = true;
|
||||
});
|
||||
addTestScopedEventListener(t, div, prefixedType, () => {
|
||||
receivedEvent = true;
|
||||
});
|
||||
|
||||
// The rewrite rules from
|
||||
// https://dom.spec.whatwg.org/#concept-event-listener-invoke step 8 do not
|
||||
// apply because isTrusted will be false.
|
||||
div.dispatchEvent(new AnimationEvent(unprefixedType));
|
||||
assert_false(receivedEvent, 'prefixed listener or handler received event');
|
||||
}, `dispatchEvent of an ${unprefixedType} event does not trigger a ` +
|
||||
`prefixed event handler or listener`);
|
||||
|
||||
promise_test(async t => {
|
||||
const div = createDiv(t);
|
||||
|
||||
let receivedEvent = false;
|
||||
addTestScopedEventHandler(t, div, prefixedHandler, () => {
|
||||
receivedEvent = true;
|
||||
});
|
||||
|
||||
triggerAnimation(div);
|
||||
await waitForEventThenAnimationFrame(t, unprefixedType);
|
||||
assert_true(receivedEvent, `received ${prefixedHandler} event`);
|
||||
}, `${prefixedHandler} event handler should trigger for an animation`);
|
||||
|
||||
promise_test(async t => {
|
||||
const div = createDiv(t);
|
||||
|
||||
let receivedPrefixedEvent = false;
|
||||
addTestScopedEventHandler(t, div, prefixedHandler, () => {
|
||||
receivedPrefixedEvent = true;
|
||||
});
|
||||
let receivedUnprefixedEvent = false;
|
||||
addTestScopedEventHandler(t, div, unprefixedHandler, () => {
|
||||
receivedUnprefixedEvent = true;
|
||||
});
|
||||
|
||||
triggerAnimation(div);
|
||||
await waitForEventThenAnimationFrame(t, unprefixedType);
|
||||
assert_true(receivedUnprefixedEvent, `received ${unprefixedHandler} event`);
|
||||
assert_false(receivedPrefixedEvent, `received ${prefixedHandler} event`);
|
||||
}, `${prefixedHandler} event handler should not trigger if an unprefixed ` +
|
||||
`event handler also exists`);
|
||||
|
||||
promise_test(async t => {
|
||||
const div = createDiv(t);
|
||||
|
||||
let receivedPrefixedEvent = false;
|
||||
addTestScopedEventHandler(t, div, prefixedHandler, () => {
|
||||
receivedPrefixedEvent = true;
|
||||
});
|
||||
let receivedUnprefixedEvent = false;
|
||||
addTestScopedEventListener(t, div, unprefixedType, () => {
|
||||
receivedUnprefixedEvent = true;
|
||||
});
|
||||
|
||||
triggerAnimation(div);
|
||||
await waitForEventThenAnimationFrame(t, unprefixedHandler);
|
||||
assert_true(receivedUnprefixedEvent, `received ${unprefixedHandler} event`);
|
||||
assert_false(receivedPrefixedEvent, `received ${prefixedHandler} event`);
|
||||
}, `${prefixedHandler} event handler should not trigger if an unprefixed ` +
|
||||
`listener also exists`);
|
||||
|
||||
promise_test(async t => {
|
||||
// We use a parent/child relationship to be able to register both prefixed
|
||||
// and unprefixed event handlers without the deduplication logic kicking in.
|
||||
const parent = createDiv(t);
|
||||
const child = createDiv(t);
|
||||
parent.appendChild(child);
|
||||
// After moving the child, we have to clean style again.
|
||||
getComputedStyle(child).transition;
|
||||
getComputedStyle(child).width;
|
||||
|
||||
let observedUnprefixedType;
|
||||
addTestScopedEventHandler(t, parent, unprefixedHandler, e => {
|
||||
observedUnprefixedType = e.type;
|
||||
});
|
||||
let observedPrefixedType;
|
||||
addTestScopedEventHandler(t, child, prefixedHandler, e => {
|
||||
observedPrefixedType = e.type;
|
||||
});
|
||||
|
||||
triggerAnimation(child);
|
||||
await waitForEventThenAnimationFrame(t, unprefixedType);
|
||||
|
||||
assert_equals(observedUnprefixedType, unprefixedType);
|
||||
assert_equals(observedPrefixedType, prefixedType);
|
||||
}, `event types for prefixed and unprefixed ${unprefixedType} event ` +
|
||||
`handlers should be named appropriately`);
|
||||
|
||||
promise_test(async t => {
|
||||
const div = createDiv(t);
|
||||
|
||||
let receivedEvent = false;
|
||||
addTestScopedEventListener(t, div, prefixedType, () => {
|
||||
receivedEvent = true;
|
||||
});
|
||||
|
||||
triggerAnimation(div);
|
||||
await waitForEventThenAnimationFrame(t, unprefixedHandler);
|
||||
assert_true(receivedEvent, `received ${prefixedType} event`);
|
||||
}, `${prefixedType} event listener should trigger for an animation`);
|
||||
|
||||
promise_test(async t => {
|
||||
const div = createDiv(t);
|
||||
|
||||
let receivedPrefixedEvent = false;
|
||||
addTestScopedEventListener(t, div, prefixedType, () => {
|
||||
receivedPrefixedEvent = true;
|
||||
});
|
||||
let receivedUnprefixedEvent = false;
|
||||
addTestScopedEventListener(t, div, unprefixedType, () => {
|
||||
receivedUnprefixedEvent = true;
|
||||
});
|
||||
|
||||
triggerAnimation(div);
|
||||
await waitForEventThenAnimationFrame(t, unprefixedHandler);
|
||||
assert_true(receivedUnprefixedEvent, `received ${unprefixedType} event`);
|
||||
assert_false(receivedPrefixedEvent, `received ${prefixedType} event`);
|
||||
}, `${prefixedType} event listener should not trigger if an unprefixed ` +
|
||||
`listener also exists`);
|
||||
|
||||
promise_test(async t => {
|
||||
const div = createDiv(t);
|
||||
|
||||
let receivedPrefixedEvent = false;
|
||||
addTestScopedEventListener(t, div, prefixedType, () => {
|
||||
receivedPrefixedEvent = true;
|
||||
});
|
||||
let receivedUnprefixedEvent = false;
|
||||
addTestScopedEventHandler(t, div, unprefixedHandler, () => {
|
||||
receivedUnprefixedEvent = true;
|
||||
});
|
||||
|
||||
triggerAnimation(div);
|
||||
await waitForEventThenAnimationFrame(t, unprefixedHandler);
|
||||
assert_true(receivedUnprefixedEvent, `received ${unprefixedType} event`);
|
||||
assert_false(receivedPrefixedEvent, `received ${prefixedType} event`);
|
||||
}, `${prefixedType} event listener should not trigger if an unprefixed ` +
|
||||
`event handler also exists`);
|
||||
|
||||
promise_test(async t => {
|
||||
// We use a parent/child relationship to be able to register both prefixed
|
||||
// and unprefixed event listeners without the deduplication logic kicking in.
|
||||
const parent = createDiv(t);
|
||||
const child = createDiv(t);
|
||||
parent.appendChild(child);
|
||||
// After moving the child, we have to clean style again.
|
||||
getComputedStyle(child).transition;
|
||||
getComputedStyle(child).width;
|
||||
|
||||
let observedUnprefixedType;
|
||||
addTestScopedEventListener(t, parent, unprefixedType, e => {
|
||||
observedUnprefixedType = e.type;
|
||||
});
|
||||
let observedPrefixedType;
|
||||
addTestScopedEventListener(t, child, prefixedType, e => {
|
||||
observedPrefixedType = e.type;
|
||||
});
|
||||
|
||||
triggerAnimation(child);
|
||||
await waitForEventThenAnimationFrame(t, unprefixedHandler);
|
||||
|
||||
assert_equals(observedUnprefixedType, unprefixedType);
|
||||
assert_equals(observedPrefixedType, prefixedType);
|
||||
}, `event types for prefixed and unprefixed ${unprefixedType} event ` +
|
||||
`listeners should be named appropriately`);
|
||||
|
||||
promise_test(async t => {
|
||||
const div = createDiv(t);
|
||||
|
||||
let receivedEvent = false;
|
||||
addTestScopedEventListener(t, div, prefixedType.toLowerCase(), () => {
|
||||
receivedEvent = true;
|
||||
});
|
||||
addTestScopedEventListener(t, div, prefixedType.toUpperCase(), () => {
|
||||
receivedEvent = true;
|
||||
});
|
||||
|
||||
triggerAnimation(div);
|
||||
await waitForEventThenAnimationFrame(t, unprefixedHandler);
|
||||
assert_false(receivedEvent, `received ${prefixedType} event`);
|
||||
}, `${prefixedType} event listener is case sensitive`);
|
||||
}
|
||||
|
||||
// Below are utility functions.
|
||||
|
||||
// Creates a div element, appends it to the document body and removes the
|
||||
// created element during test cleanup.
|
||||
function createDiv(test) {
|
||||
const element = document.createElement('div');
|
||||
element.classList.add('baseStyle');
|
||||
document.body.appendChild(element);
|
||||
test.add_cleanup(() => {
|
||||
element.remove();
|
||||
});
|
||||
|
||||
// Flush style before returning. Some browsers only do partial style re-calc,
|
||||
// so ask for all important properties to make sure they are applied.
|
||||
getComputedStyle(element).transition;
|
||||
getComputedStyle(element).width;
|
||||
|
||||
return element;
|
||||
}
|
||||
|
||||
// Adds an event handler for |handlerName| (calling |callback|) to the given
|
||||
// |target|, that will automatically be cleaned up at the end of the test.
|
||||
function addTestScopedEventHandler(test, target, handlerName, callback) {
|
||||
assert_regexp_match(
|
||||
handlerName, /^on/, 'Event handler names must start with "on"');
|
||||
assert_equals(target[handlerName], null,
|
||||
`${handlerName} must be supported and not previously set`);
|
||||
target[handlerName] = callback;
|
||||
// We need this cleaned up even if the event handler doesn't run.
|
||||
test.add_cleanup(() => {
|
||||
if (target[handlerName])
|
||||
target[handlerName] = null;
|
||||
});
|
||||
}
|
||||
|
||||
// Adds an event listener for |type| (calling |callback|) to the given
|
||||
// |target|, that will automatically be cleaned up at the end of the test.
|
||||
function addTestScopedEventListener(test, target, type, callback) {
|
||||
target.addEventListener(type, callback);
|
||||
// We need this cleaned up even if the event handler doesn't run.
|
||||
test.add_cleanup(() => {
|
||||
target.removeEventListener(type, callback);
|
||||
});
|
||||
}
|
||||
|
||||
// Returns a promise that will resolve once the passed event (|eventName|) has
|
||||
// triggered and one more animation frame has happened. Automatically chooses
|
||||
// between an event handler or event listener based on whether |eventName|
|
||||
// begins with 'on'.
|
||||
//
|
||||
// We always listen on window as we don't want to interfere with the test via
|
||||
// triggering the prefixed event deduplication logic.
|
||||
function waitForEventThenAnimationFrame(test, eventName) {
|
||||
return new Promise((resolve, _) => {
|
||||
const eventFunc = eventName.startsWith('on')
|
||||
? addTestScopedEventHandler : addTestScopedEventListener;
|
||||
eventFunc(test, window, eventName, () => {
|
||||
// rAF once to give the event under test time to come through.
|
||||
requestAnimationFrame(resolve);
|
||||
});
|
||||
});
|
||||
}
|
|
@ -0,0 +1,20 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>Prefixed CSS Animation end events</title>
|
||||
<link rel="help" href="https://dom.spec.whatwg.org/#concept-event-listener-invoke">
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<body>
|
||||
|
||||
<script src="resources/prefixed-animation-event-tests.js"></script>
|
||||
<script>
|
||||
'use strict';
|
||||
|
||||
runAnimationEventTests({
|
||||
unprefixedType: 'animationend',
|
||||
prefixedType: 'webkitAnimationEnd',
|
||||
animationCssStyle: '1ms',
|
||||
});
|
||||
</script>
|
|
@ -0,0 +1,20 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>Prefixed CSS Animation iteration events</title>
|
||||
<link rel="help" href="https://dom.spec.whatwg.org/#concept-event-listener-invoke">
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<body>
|
||||
|
||||
<script src="resources/prefixed-animation-event-tests.js"></script>
|
||||
<script>
|
||||
'use strict';
|
||||
|
||||
runAnimationEventTests({
|
||||
unprefixedType: 'animationiteration',
|
||||
prefixedType: 'webkitAnimationIteration',
|
||||
animationCssStyle: '50ms 2',
|
||||
});
|
||||
</script>
|
|
@ -0,0 +1,20 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>Prefixed CSS Animation start events</title>
|
||||
<link rel="help" href="https://dom.spec.whatwg.org/#concept-event-listener-invoke">
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<body>
|
||||
|
||||
<script src="resources/prefixed-animation-event-tests.js"></script>
|
||||
<script>
|
||||
'use strict';
|
||||
|
||||
runAnimationEventTests({
|
||||
unprefixedType: 'animationstart',
|
||||
prefixedType: 'webkitAnimationStart',
|
||||
animationCssStyle: '1ms',
|
||||
});
|
||||
</script>
|
|
@ -0,0 +1,21 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>Prefixed CSS Transition End event</title>
|
||||
<link rel="help" href="https://dom.spec.whatwg.org/#concept-event-listener-invoke">
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<body>
|
||||
|
||||
<script src="resources/prefixed-animation-event-tests.js"></script>
|
||||
<script>
|
||||
'use strict';
|
||||
|
||||
runAnimationEventTests({
|
||||
isTransition: true,
|
||||
unprefixedType: 'transitionend',
|
||||
prefixedType: 'webkitTransitionEnd',
|
||||
animationCssStyle: '1ms',
|
||||
});
|
||||
</script>
|
|
@ -147,11 +147,11 @@
|
|||
<script>
|
||||
|
||||
test(function(t) {
|
||||
assert_equals(passwordField.ariaDetailsElement, null);
|
||||
passwordField.ariaDetailsElement = listItem1;
|
||||
assert_equals(passwordField.ariaDetailsElements, null);
|
||||
passwordField.ariaDetailsElements = [ listItem1 ];
|
||||
assert_equals(passwordField.getAttribute("aria-details"), "listItem1");
|
||||
|
||||
passwordField.ariaDetailsElement = listItem2;
|
||||
passwordField.ariaDetailsElements = [ listItem2 ];
|
||||
assert_equals(passwordField.getAttribute("aria-details"), "listItem2");
|
||||
}, "aria-details");
|
||||
</script>
|
||||
|
|
|
@ -21,7 +21,7 @@ interface mixin AriaAttributes {
|
|||
attribute FrozenArray<Element>? ariaControlsElements;
|
||||
attribute DOMString? ariaCurrent;
|
||||
attribute FrozenArray<Element>? ariaDescribedByElements;
|
||||
attribute Element? ariaDetailsElement;
|
||||
attribute Element? ariaDetailsElements;
|
||||
attribute DOMString? ariaDisabled;
|
||||
attribute Element? ariaErrorMessageElement;
|
||||
attribute DOMString? ariaExpanded;
|
||||
|
|
|
@ -1,16 +1,5 @@
|
|||
'use strict';
|
||||
|
||||
function toMojoNDEFPushTarget(target) {
|
||||
switch (target) {
|
||||
case 'peer':
|
||||
return device.mojom.NDEFPushTarget.PEER;
|
||||
case 'tag':
|
||||
return device.mojom.NDEFPushTarget.TAG;
|
||||
}
|
||||
|
||||
return device.mojom.NDEFPushTarget.ANY;
|
||||
}
|
||||
|
||||
// Converts between NDEFMessageInit https://w3c.github.io/web-nfc/#dom-ndefmessage
|
||||
// and mojom.NDEFMessage structure, so that watch function can be tested.
|
||||
function toMojoNDEFMessage(message) {
|
||||
|
@ -92,11 +81,6 @@ function assertNDEFPushOptionsEqual(provided, received) {
|
|||
assert_equals(provided.ignoreRead, !!received.ignoreRead);
|
||||
else
|
||||
assert_equals(!!received.ignore_read, true);
|
||||
|
||||
if (provided.target !== undefined)
|
||||
assert_equals(toMojoNDEFPushTarget(provided.target), received.target);
|
||||
else
|
||||
assert_equals(received.target, device.mojom.NDEFPushTarget.ANY);
|
||||
}
|
||||
|
||||
// Compares NDEFReaderOptions structures that were provided to API and
|
||||
|
@ -205,13 +189,8 @@ var WebNFCTest = (() => {
|
|||
});
|
||||
}
|
||||
|
||||
async cancelPush(target) {
|
||||
if (this.pending_push_options_ &&
|
||||
((target === device.mojom.NDEFPushTarget.ANY) ||
|
||||
(this.pending_push_options_.target === target))) {
|
||||
async cancelPush() {
|
||||
this.cancelPendingPushOperation();
|
||||
}
|
||||
|
||||
return createNDEFError(null);
|
||||
}
|
||||
|
||||
|
|
|
@ -328,6 +328,10 @@
|
|||
}, 'NDEFRecord constructor with record type string being treated as case sensitive');
|
||||
|
||||
test(() => {
|
||||
assert_throws(new TypeError, () => new NDEFRecord(createRecord(
|
||||
'example.com:hellö', test_buffer_data)),
|
||||
'The external type must be an ASCII string.');
|
||||
|
||||
// Length of the external type is 255, OK.
|
||||
const record = new NDEFRecord(createRecord(
|
||||
[...Array(251)].map(_ => 'a').join('') + ':xyz', test_buffer_data));
|
||||
|
|
|
@ -220,13 +220,6 @@ promise_test(async t => {
|
|||
t, 'NotSupportedError', writer.push(new ArrayBuffer(32 * 1024 + 1)));
|
||||
}, "Reject promise with NotSupportedError if NFC message size exceeds 32KB.");
|
||||
|
||||
promise_test(async t => {
|
||||
const writer = new NDEFWriter();
|
||||
await promise_rejects(
|
||||
t, new TypeError(), writer.push(test_text_data, {target: "invalid"}));
|
||||
}, "NDEFWriter.push should fail with TypeError when invalid target value is \
|
||||
provided.");
|
||||
|
||||
promise_test(async () => {
|
||||
await new Promise((resolve,reject) => {
|
||||
const iframe = document.createElement('iframe');
|
||||
|
@ -338,13 +331,13 @@ nfc_test(async (t, mockNFC) => {
|
|||
nfc_test(async (t, mockNFC) => {
|
||||
const writer = new NDEFWriter();
|
||||
await writer.push(test_text_data);
|
||||
assertNDEFPushOptionsEqual(createNDEFPushOptions('any', true),
|
||||
assertNDEFPushOptionsEqual(createNDEFPushOptions(true),
|
||||
mockNFC.pushOptions());
|
||||
}, "Check that default NDEFPushOptions values are correctly set.");
|
||||
|
||||
nfc_test(async (t, mockNFC) => {
|
||||
const writer = new NDEFWriter();
|
||||
let ndefPushOptions = createNDEFPushOptions('tag', false);
|
||||
let ndefPushOptions = createNDEFPushOptions(false);
|
||||
await writer.push(test_text_data, ndefPushOptions);
|
||||
assertNDEFPushOptionsEqual(ndefPushOptions, mockNFC.pushOptions());
|
||||
}, "Check that provided NDEFPushOptions values are correctly converted.");
|
||||
|
@ -385,8 +378,8 @@ nfc_test(async (t, mockNFC) => {
|
|||
const writer1 = new NDEFWriter();
|
||||
const writer2 = new NDEFWriter();
|
||||
|
||||
const ndefPushOptions1 = createNDEFPushOptions('tag', false);
|
||||
const ndefPushOptions2 = createNDEFPushOptions('tag', true);
|
||||
const ndefPushOptions1 = createNDEFPushOptions(false);
|
||||
const ndefPushOptions2 = createNDEFPushOptions(true);
|
||||
const p1 = writer1.push(test_text_data, ndefPushOptions1);
|
||||
const p2 = writer2.push(test_url_data, ndefPushOptions2);
|
||||
|
||||
|
|
|
@ -125,8 +125,8 @@ function createUrlRecord(url, isAbsUrl) {
|
|||
return createRecord('url', url, test_record_id);
|
||||
}
|
||||
|
||||
function createNDEFPushOptions(target, ignoreRead) {
|
||||
return {target, ignoreRead};
|
||||
function createNDEFPushOptions(ignoreRead) {
|
||||
return {ignoreRead};
|
||||
}
|
||||
|
||||
// Compares NDEFMessageSource that was provided to the API
|
||||
|
|
|
@ -1205,27 +1205,14 @@
|
|||
// Wait a little, just in case some stray events fire
|
||||
await new Promise(r => t.step_timeout(r, 100));
|
||||
|
||||
// Receiving an RTCP bye should generate a mute event. How often this
|
||||
// happens depends upon the browser and on timing. Rather than try to
|
||||
// match an individual browser's current behaviour, this checks to see
|
||||
// that we receive at least the minimum number of expected mute and
|
||||
// unmute events.
|
||||
assert_greater_than_equal(countMuteAudio1.count, 1,
|
||||
"Expect 1 mute event for pc1's audio track");
|
||||
assert_greater_than_equal(countMuteVideo1.count, 1,
|
||||
"Expect 1 mute event for pc1's video track");
|
||||
assert_greater_than_equal(countMuteAudio2.count, 1,
|
||||
"Expect 1 mute event for pc2's audio track");
|
||||
assert_greater_than_equal(countMuteVideo2.count, 1,
|
||||
"Expect 1 mute event for pc2's video track");
|
||||
assert_greater_than_equal(countUnmuteAudio1.count, 2,
|
||||
"Expect 2 unmute events for pc1's audio track");
|
||||
assert_greater_than_equal(countUnmuteVideo1.count, 2,
|
||||
"Expect 2 unmute events for pc1's video track");
|
||||
assert_greater_than_equal(countUnmuteAudio2.count, 2,
|
||||
"Expect 2 unmute events for pc2's audio track");
|
||||
assert_greater_than_equal(countUnmuteVideo2.count, 2,
|
||||
"Expect 2 unmute events for pc2's video track");
|
||||
assert_equals(1, countMuteAudio1.count, "Got 1 mute event for pc1's audio track");
|
||||
assert_equals(1, countMuteVideo1.count, "Got 1 mute event for pc1's video track");
|
||||
assert_equals(1, countMuteAudio2.count, "Got 1 mute event for pc2's audio track");
|
||||
assert_equals(1, countMuteVideo2.count, "Got 1 mute event for pc2's video track");
|
||||
assert_equals(2, countUnmuteAudio1.count, "Got 2 unmute events for pc1's audio track");
|
||||
assert_equals(2, countUnmuteVideo1.count, "Got 2 unmute events for pc1's video track");
|
||||
assert_equals(2, countUnmuteAudio2.count, "Got 2 unmute events for pc2's audio track");
|
||||
assert_equals(2, countUnmuteVideo2.count, "Got 2 unmute events for pc2's video track");
|
||||
};
|
||||
|
||||
const checkStop = async t => {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue