Changeset 287788 in webkit


Ignore:
Timestamp:
Jan 7, 2022, 2:56:47 PM (4 years ago)
Author:
Chris Dumez
Message:

Resync web-platform-tests/dom from upstream
https://bugs.webkit.org/show_bug.cgi?id=234963

Reviewed by Geoffrey Garen.

Resync web-platform-tests/dom from upstream 84b2be5b17e8542dea2.

  • resources/resource-files.json:
  • web-platform-tests/dom/*: Updated.
Location:
trunk/LayoutTests
Files:
14 added
20 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/TestExpectations

    r287757 r287788  
    50815081webkit.org/b/183994 imported/w3c/web-platform-tests/css/cssom/css-style-attr-decl-block.html [ Failure ]
    50825082
     5083# Test is crashing in Debug builds since import.
     5084webkit.org/b/234977 [ Debug ] imported/w3c/web-platform-tests/dom/events/focus-event-document-move.html [ Skip ]
     5085
    50835086# Plugins
    50845087# FIXME: Remove these tests.
  • trunk/LayoutTests/imported/w3c/ChangeLog

    r287785 r287788  
     12022-01-07  Chris Dumez  <cdumez@apple.com>
     2
     3        Resync web-platform-tests/dom from upstream
     4        https://bugs.webkit.org/show_bug.cgi?id=234963
     5
     6        Reviewed by Geoffrey Garen.
     7
     8        Resync web-platform-tests/dom from upstream 84b2be5b17e8542dea2.
     9
     10        * resources/resource-files.json:
     11        * web-platform-tests/dom/*: Updated.
     12
    1132022-01-07  Chris Dumez  <cdumez@apple.com>
    214
  • trunk/LayoutTests/imported/w3c/resources/resource-files.json

    r287499 r287788  
    16171617        "web-platform-tests/dom/nodes/node-appendchild-crash.html",
    16181618        "web-platform-tests/dom/nodes/query-target-in-load-event.part.html",
     1619        "web-platform-tests/dom/nodes/remove-from-shadow-host-and-adopt-into-iframe-ref.html",
    16191620        "web-platform-tests/dom/ranges/Range-test-iframe.html",
     1621        "web-platform-tests/dom/slot-recalc-ref.html",
     1622        "web-platform-tests/dom/traversal/support/TreeWalker-acceptNode-filter-cross-realm-null-browsing-context-subframe.html",
     1623        "web-platform-tests/dom/traversal/support/TreeWalker-acceptNode-filter-cross-realm-subframe.html",
    16201624        "web-platform-tests/dom/traversal/unfinished/001.xml",
    16211625        "web-platform-tests/dom/traversal/unfinished/002.xml",
  • trunk/LayoutTests/imported/w3c/web-platform-tests/dom/abort/event.any-expected.txt

    r286904 r287788  
    1414PASS throwIfAborted() should throw primitive abort.reason if signal aborted
    1515PASS throwIfAborted() should not throw if signal not aborted
     16PASS AbortSignal.reason returns the same DOMException
     17PASS AbortController.signal.reason returns the same DOMException
    1618
  • trunk/LayoutTests/imported/w3c/web-platform-tests/dom/abort/event.any.js

    r286904 r287788  
    159159}, "throwIfAborted() should not throw if signal not aborted");
    160160
     161test(t => {
     162  const signal = AbortSignal.abort();
     163
     164  assert_true(
     165    signal.reason instanceof DOMException,
     166    "signal.reason is a DOMException"
     167  );
     168  assert_equals(
     169    signal.reason,
     170    signal.reason,
     171    "signal.reason returns the same DOMException"
     172  );
     173}, "AbortSignal.reason returns the same DOMException");
     174
     175test(t => {
     176  const controller = new AbortController();
     177  controller.abort();
     178
     179  assert_true(
     180    controller.signal.reason instanceof DOMException,
     181    "signal.reason is a DOMException"
     182  );
     183  assert_equals(
     184    controller.signal.reason,
     185    controller.signal.reason,
     186    "signal.reason returns the same DOMException"
     187  );
     188}, "AbortController.signal.reason returns the same DOMException");
     189
    161190done();
  • trunk/LayoutTests/imported/w3c/web-platform-tests/dom/abort/event.any.worker-expected.txt

    r286904 r287788  
    1414PASS throwIfAborted() should throw primitive abort.reason if signal aborted
    1515PASS throwIfAborted() should not throw if signal not aborted
     16PASS AbortSignal.reason returns the same DOMException
     17PASS AbortController.signal.reason returns the same DOMException
    1618
  • trunk/LayoutTests/imported/w3c/web-platform-tests/dom/abort/w3c-import.log

    r279015 r287788  
    1717/LayoutTests/imported/w3c/web-platform-tests/dom/abort/AbortSignal.any.js
    1818/LayoutTests/imported/w3c/web-platform-tests/dom/abort/event.any.js
     19/LayoutTests/imported/w3c/web-platform-tests/dom/abort/reason-constructor.html
  • trunk/LayoutTests/imported/w3c/web-platform-tests/dom/events/AddEventListenerOptions-passive.any-expected.txt

    r285010 r287788  
    11
    22PASS Supports passive option on addEventListener only
    3 FAIL preventDefault should be ignored if-and-only-if the passive option is true assert_equals: Incorrect defaultPrevented for options: undefined expected (boolean) true but got (undefined) undefined
     3PASS preventDefault should be ignored if-and-only-if the passive option is true
    44PASS returnValue should be ignored if-and-only-if the passive option is true
    5 FAIL passive behavior of one listener should be unaffected by the presence of other listeners assert_equals: Incorrect defaultPrevented for options: {} expected (boolean) true but got (undefined) undefined
     5PASS passive behavior of one listener should be unaffected by the presence of other listeners
    66PASS Equivalence of option values
    77
  • trunk/LayoutTests/imported/w3c/web-platform-tests/dom/events/AddEventListenerOptions-passive.any.js

    r285010 r287788  
    2323}, "Supports passive option on addEventListener only");
    2424
    25 function testPassiveValue(optionsValue, expectedDefaultPrevented) {
     25function testPassiveValue(optionsValue, expectedDefaultPrevented, existingEventTarget) {
    2626  var defaultPrevented = undefined;
    2727  var handler = function handler(e) {
     
    3030    defaultPrevented = e.defaultPrevented;
    3131  }
    32   const et = new EventTarget();
     32  const et = existingEventTarget || new EventTarget();
    3333  et.addEventListener('test', handler, optionsValue);
    34   var uncanceled = document.body.dispatchEvent(new Event('test', {bubbles: true, cancelable: true}));
     34  var uncanceled = et.dispatchEvent(new Event('test', {bubbles: true, cancelable: true}));
    3535
    3636  assert_equals(defaultPrevented, expectedDefaultPrevented, "Incorrect defaultPrevented for options: " + JSON.stringify(optionsValue));
     
    9090  et.addEventListener('test', dummyHandler2);
    9191
    92   testPassiveValue(optionsValue, expectedDefaultPrevented);
     92  testPassiveValue(optionsValue, expectedDefaultPrevented, et);
    9393
    9494  assert_true(handlerInvoked1, "Extra passive handler not invoked");
  • trunk/LayoutTests/imported/w3c/web-platform-tests/dom/events/AddEventListenerOptions-passive.any.worker-expected.txt

    r285010 r287788  
    11
    22PASS Supports passive option on addEventListener only
    3 FAIL preventDefault should be ignored if-and-only-if the passive option is true Can't find variable: document
     3PASS preventDefault should be ignored if-and-only-if the passive option is true
    44PASS returnValue should be ignored if-and-only-if the passive option is true
    5 FAIL passive behavior of one listener should be unaffected by the presence of other listeners Can't find variable: document
     5PASS passive behavior of one listener should be unaffected by the presence of other listeners
    66PASS Equivalence of option values
    77
  • trunk/LayoutTests/imported/w3c/web-platform-tests/dom/events/EventTarget-removeEventListener.any.js

    r285010 r287788  
    33// Step 1.
    44test(function() {
    5   assert_equals(document.removeEventListener("x", null, false), undefined);
    6   assert_equals(document.removeEventListener("x", null, true), undefined);
    7   assert_equals(document.removeEventListener("x", null), undefined);
     5  assert_equals(globalThis.removeEventListener("x", null, false), undefined);
     6  assert_equals(globalThis.removeEventListener("x", null, true), undefined);
     7  assert_equals(globalThis.removeEventListener("x", null), undefined);
    88}, "removing a null event listener should succeed");
  • trunk/LayoutTests/imported/w3c/web-platform-tests/dom/events/EventTarget-removeEventListener.any.worker-expected.txt

    r285010 r287788  
    11
    2 FAIL removing a null event listener should succeed Can't find variable: document
     2PASS removing a null event listener should succeed
    33
  • trunk/LayoutTests/imported/w3c/web-platform-tests/dom/events/resources/w3c-import.log

    r262254 r287788  
    1616List of files:
    1717/LayoutTests/imported/w3c/web-platform-tests/dom/events/resources/event-global-extra-frame.html
     18/LayoutTests/imported/w3c/web-platform-tests/dom/events/resources/event-global-is-still-set-when-coercing-beforeunload-result-frame.html
    1819/LayoutTests/imported/w3c/web-platform-tests/dom/events/resources/prefixed-animation-event-tests.js
  • trunk/LayoutTests/imported/w3c/web-platform-tests/dom/events/w3c-import.log

    r285010 r287788  
    5454/LayoutTests/imported/w3c/web-platform-tests/dom/events/Event-stopPropagation-cancel-bubbling.html
    5555/LayoutTests/imported/w3c/web-platform-tests/dom/events/Event-subclasses-constructors.html
     56/LayoutTests/imported/w3c/web-platform-tests/dom/events/Event-timestamp-cross-realm-getter.html
    5657/LayoutTests/imported/w3c/web-platform-tests/dom/events/Event-timestamp-high-resolution.html
    5758/LayoutTests/imported/w3c/web-platform-tests/dom/events/Event-timestamp-high-resolution.https.html
     
    8182/LayoutTests/imported/w3c/web-platform-tests/dom/events/event-disabled-dynamic.html
    8283/LayoutTests/imported/w3c/web-platform-tests/dom/events/event-global-extra.window.js
     84/LayoutTests/imported/w3c/web-platform-tests/dom/events/event-global-is-still-set-when-coercing-beforeunload-result.html
     85/LayoutTests/imported/w3c/web-platform-tests/dom/events/event-global-set-before-handleEvent-lookup.any.js
    8386/LayoutTests/imported/w3c/web-platform-tests/dom/events/event-global.html
    8487/LayoutTests/imported/w3c/web-platform-tests/dom/events/event-global.worker.js
     88/LayoutTests/imported/w3c/web-platform-tests/dom/events/focus-event-document-move.html
    8589/LayoutTests/imported/w3c/web-platform-tests/dom/events/keypress-dispatch-crash.html
    8690/LayoutTests/imported/w3c/web-platform-tests/dom/events/legacy-pre-activation-behavior.window.js
  • trunk/LayoutTests/imported/w3c/web-platform-tests/dom/historical-expected.txt

    r285010 r287788  
    1919PASS Historical DOM features must be removed: UserDataHandler
    2020PASS Historical DOM features must be removed: RangeException
     21FAIL Historical DOM features must be removed: SVGPathSegList assert_false: expected false got true
    2122PASS Historical DOM features must be removed: createEntityReference
    22 FAIL Historical DOM features must be removed: xmlEncoding assert_equals: expected (undefined) undefined but got (object) null
    23 FAIL Historical DOM features must be removed: xmlStandalone assert_equals: expected (undefined) undefined but got (boolean) false
    24 FAIL Historical DOM features must be removed: xmlVersion assert_equals: expected (undefined) undefined but got (object) null
     23FAIL Historical DOM features must be removed: xmlEncoding assert_false: expected false got true
     24FAIL Historical DOM features must be removed: xmlStandalone assert_false: expected false got true
     25FAIL Historical DOM features must be removed: xmlVersion assert_false: expected false got true
    2526PASS Historical DOM features must be removed: strictErrorChecking
    2627PASS Historical DOM features must be removed: domConfig
  • trunk/LayoutTests/imported/w3c/web-platform-tests/dom/historical.html

    r285010 r287788  
    77function isInterfaceRemoved(name) {
    88  test(function() {
     9    assert_false(name in window)
    910    assert_equals(window[name], undefined)
    1011  }, "Historical DOM features must be removed: " + name)
     
    2930  "TypeInfo",
    3031  "UserDataHandler",
    31   "RangeException" // DOM Range
     32  "RangeException", // DOM Range
     33  "SVGPathSegList"
    3234]
    3335removedInterfaces.forEach(isInterfaceRemoved)
     
    3638  test(function() {
    3739    var doc = document.implementation.createDocument(null,null,null)
     40    assert_false(name in document)
    3841    assert_equals(document[name], undefined)
     42    assert_false(name in doc)
    3943    assert_equals(doc[name], undefined)
    4044  }, "Historical DOM features must be removed: " + name)
     
    6670  // https://github.com/whatwg/html/commit/e236f46820b93d6fe2e2caae0363331075c6c4fb
    6771  assert_false("load" in document);
     72  assert_equals(document["load"], undefined)
    6873}, "document.load");
    6974
     
    7277  var doc = document.implementation.createDocument(null, null, null);
    7378  assert_false("load" in doc);
     79  assert_equals(doc["load"], undefined)
    7480}, "XMLDocument.load");
    7581
    7682test(function() {
     83  assert_false("getFeature" in document.implementation)
    7784  assert_equals(document.implementation["getFeature"], undefined)
    7885}, "DOMImplementation.getFeature() must be removed.")
     
    8188  test(function() {
    8289    var ele = document.createElementNS("test", "test")
     90    assert_false(name in document.body)
    8391    assert_equals(document.body[name], undefined)
     92    assert_false(name in ele)
    8493    assert_equals(ele[name], undefined)
    8594  }, "Historical DOM features must be removed: " + name)
     
    96105  test(function() {
    97106    var attr = document.createAttribute("test")
     107    assert_false(name in attr)
    98108    assert_equals(attr[name], undefined)
    99109  }, "Attr member must be removed: " + name)
     
    108118  test(function() {
    109119    var doctype = document.implementation.createDocumentType("test", "", "")
     120    assert_false(name in doctype)
    110121    assert_equals(doctype[name], undefined)
    111122  }, "DocumentType member must be removed: " + name)
     
    121132  test(function() {
    122133    var text = document.createTextNode("test")
     134    assert_false(name in text)
    123135    assert_equals(text[name], undefined)
    124136  }, "Text member must be removed: " + name)
     
    135147    var doctype = document.implementation.createDocumentType("test", "", "")
    136148    var text = document.createTextNode("test")
     149    assert_false(name in doc)
    137150    assert_equals(doc[name], undefined)
     151    assert_false(name in doctype)
    138152    assert_equals(doctype[name], undefined)
     153    assert_false(name in text)
    139154    assert_equals(text[name], undefined)
    140155  }, "Node member must be removed: " + name)
     
    156171function isRemovedFromWindow(name) {
    157172  test(function() {
     173    assert_false(name in window)
    158174    assert_equals(window[name], undefined)
    159175  }, "Window member must be removed: " + name)
     
    166182function isRemovedFromEvent(name) {
    167183  test(() => {
     184    assert_false(name in Event)
    168185    assert_equals(Event[name], undefined)
    169186  }, "Event should not have this constant: " + name)
     
    195212EventPrototypeRemoved.forEach(name => {
    196213  test(() => {
     214    assert_false(name in Event.prototype)
    197215    assert_equals(Event.prototype[name], undefined)
     216    assert_false(name in new Event("test"))
    198217    assert_equals((new Event("test"))[name], undefined)
    199218  }, "Event.prototype should not have this property: " + name)
  • trunk/LayoutTests/imported/w3c/web-platform-tests/dom/nodes/w3c-import.log

    r279015 r287788  
    262262/LayoutTests/imported/w3c/web-platform-tests/dom/nodes/remove-and-adopt-thcrash.html
    263263/LayoutTests/imported/w3c/web-platform-tests/dom/nodes/remove-from-shadow-host-and-adopt-into-iframe-expected.html
     264/LayoutTests/imported/w3c/web-platform-tests/dom/nodes/remove-from-shadow-host-and-adopt-into-iframe-ref.html
    264265/LayoutTests/imported/w3c/web-platform-tests/dom/nodes/remove-from-shadow-host-and-adopt-into-iframe.html
    265266/LayoutTests/imported/w3c/web-platform-tests/dom/nodes/remove-unscopable.html
  • trunk/LayoutTests/imported/w3c/web-platform-tests/dom/traversal/support/w3c-import.log

    r248705 r287788  
    1515------------------------------------------------------------------------
    1616List of files:
     17/LayoutTests/imported/w3c/web-platform-tests/dom/traversal/support/TreeWalker-acceptNode-filter-cross-realm-null-browsing-context-subframe.html
     18/LayoutTests/imported/w3c/web-platform-tests/dom/traversal/support/TreeWalker-acceptNode-filter-cross-realm-subframe.html
    1719/LayoutTests/imported/w3c/web-platform-tests/dom/traversal/support/assert-node.js
  • trunk/LayoutTests/imported/w3c/web-platform-tests/dom/traversal/w3c-import.log

    r248705 r287788  
    1818/LayoutTests/imported/w3c/web-platform-tests/dom/traversal/NodeIterator-removal.html
    1919/LayoutTests/imported/w3c/web-platform-tests/dom/traversal/NodeIterator.html
     20/LayoutTests/imported/w3c/web-platform-tests/dom/traversal/TreeWalker-acceptNode-filter-cross-realm-null-browsing-context.html
     21/LayoutTests/imported/w3c/web-platform-tests/dom/traversal/TreeWalker-acceptNode-filter-cross-realm.html
    2022/LayoutTests/imported/w3c/web-platform-tests/dom/traversal/TreeWalker-acceptNode-filter.html
    2123/LayoutTests/imported/w3c/web-platform-tests/dom/traversal/TreeWalker-basic.html
  • trunk/LayoutTests/imported/w3c/web-platform-tests/dom/w3c-import.log

    r274167 r287788  
    2323/LayoutTests/imported/w3c/web-platform-tests/dom/idlharness.window.js
    2424/LayoutTests/imported/w3c/web-platform-tests/dom/interface-objects.html
     25/LayoutTests/imported/w3c/web-platform-tests/dom/slot-recalc-ref.html
    2526/LayoutTests/imported/w3c/web-platform-tests/dom/slot-recalc.html
    2627/LayoutTests/imported/w3c/web-platform-tests/dom/svg-insert-crash.html
Note: See TracChangeset for help on using the changeset viewer.