Changeset 203377 in webkit
- Timestamp:
- Jul 18, 2016, 3:33:32 PM (9 years ago)
- Location:
- trunk
- Files:
-
- 2 added
- 6 deleted
- 9 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r203374 r203377 1 2016-07-18 Chris Dumez <cdumez@apple.com> 2 3 The 2 first parameters to addEventListener() / removeEventListener() should be mandatory 4 https://bugs.webkit.org/show_bug.cgi?id=158008 5 6 Reviewed by Darin Adler. 7 8 * fast/dom/Window/window-legacy-event-listener-expected.txt: Removed. 9 * fast/dom/Window/window-legacy-event-listener.html: Removed. 10 * fast/dom/XMLHttpRequest-legacy-event-listener-expected.txt: Removed. 11 * fast/dom/XMLHttpRequest-legacy-event-listener.html: Removed. 12 * fast/dom/node-legacy-event-listener-expected.txt: Removed. 13 * fast/dom/node-legacy-event-listener.html: Removed. 14 Drop legacy tests that expect the addEventListener() / removeEventListener() 15 parameters to be optional. 16 17 * fast/dom/eventtarget-api-parameters-expected.txt: Added. 18 * fast/dom/eventtarget-api-parameters.html: Added. 19 Add layout test to check that the 2 first parameters of addEventListener() 20 and removeEventListener() are now mandatory. It also checks that the 21 second parameter is nullable. 22 23 * media/video-remote-control-playpause.html: 24 Drop useless call to addEventListener() without a listener as it now throws. 25 1 26 2016-07-18 Brent Fulgham <bfulgham@apple.com> 2 27 -
trunk/LayoutTests/imported/w3c/ChangeLog
r203347 r203377 1 2016-07-18 Chris Dumez <cdumez@apple.com> 2 3 The 2 first parameters to addEventListener() / removeEventListener() should be mandatory 4 https://bugs.webkit.org/show_bug.cgi?id=158008 5 6 Reviewed by Darin Adler. 7 8 Rebaseline several W3C tests now that more checks are passing. 9 10 * web-platform-tests/XMLHttpRequest/interfaces-expected.txt: 11 * web-platform-tests/dom/interfaces-expected.txt: 12 * web-platform-tests/html/dom/interfaces-expected.txt: 13 1 14 2016-07-18 Youenn Fablet <youenn@apple.com> 2 15 -
trunk/LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/interfaces-expected.txt
r200309 r203377 30 30 PASS XMLHttpRequestEventTarget interface: (new XMLHttpRequest()).upload must inherit property "onloadend" with the proper type (6) 31 31 PASS EventTarget interface: (new XMLHttpRequest()).upload must inherit property "addEventListener" with the proper type (0) 32 FAIL EventTarget interface: calling addEventListener(DOMString,EventListener,boolean) on (new XMLHttpRequest()).upload with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 33 fn.apply(obj, args); 34 }" did not throw 32 PASS EventTarget interface: calling addEventListener(DOMString,EventListener,boolean) on (new XMLHttpRequest()).upload with too few arguments must throw TypeError 35 33 PASS EventTarget interface: (new XMLHttpRequest()).upload must inherit property "removeEventListener" with the proper type (1) 36 FAIL EventTarget interface: calling removeEventListener(DOMString,EventListener,boolean) on (new XMLHttpRequest()).upload with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 37 fn.apply(obj, args); 38 }" did not throw 34 PASS EventTarget interface: calling removeEventListener(DOMString,EventListener,boolean) on (new XMLHttpRequest()).upload with too few arguments must throw TypeError 39 35 PASS EventTarget interface: (new XMLHttpRequest()).upload must inherit property "dispatchEvent" with the proper type (2) 40 36 PASS EventTarget interface: calling dispatchEvent(Event) on (new XMLHttpRequest()).upload with too few arguments must throw TypeError … … 115 111 PASS XMLHttpRequestEventTarget interface: new XMLHttpRequest() must inherit property "onloadend" with the proper type (6) 116 112 PASS EventTarget interface: new XMLHttpRequest() must inherit property "addEventListener" with the proper type (0) 117 FAIL EventTarget interface: calling addEventListener(DOMString,EventListener,boolean) on new XMLHttpRequest() with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 118 fn.apply(obj, args); 119 }" did not throw 113 PASS EventTarget interface: calling addEventListener(DOMString,EventListener,boolean) on new XMLHttpRequest() with too few arguments must throw TypeError 120 114 PASS EventTarget interface: new XMLHttpRequest() must inherit property "removeEventListener" with the proper type (1) 121 FAIL EventTarget interface: calling removeEventListener(DOMString,EventListener,boolean) on new XMLHttpRequest() with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 122 fn.apply(obj, args); 123 }" did not throw 115 PASS EventTarget interface: calling removeEventListener(DOMString,EventListener,boolean) on new XMLHttpRequest() with too few arguments must throw TypeError 124 116 PASS EventTarget interface: new XMLHttpRequest() must inherit property "dispatchEvent" with the proper type (2) 125 117 PASS EventTarget interface: calling dispatchEvent(Event) on new XMLHttpRequest() with too few arguments must throw TypeError -
trunk/LayoutTests/imported/w3c/web-platform-tests/dom/interfaces-expected.txt
r203333 r203377 438 438 PASS Node interface: calling removeChild(Node) on new Document() with too few arguments must throw TypeError 439 439 PASS EventTarget interface: new Document() must inherit property "addEventListener" with the proper type (0) 440 FAIL EventTarget interface: calling addEventListener(DOMString,EventListener,[object Object],[object Object]) on new Document() with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 441 fn.apply(obj, args); 442 }" did not throw 440 PASS EventTarget interface: calling addEventListener(DOMString,EventListener,[object Object],[object Object]) on new Document() with too few arguments must throw TypeError 443 441 PASS EventTarget interface: new Document() must inherit property "removeEventListener" with the proper type (1) 444 FAIL EventTarget interface: calling removeEventListener(DOMString,EventListener,[object Object],[object Object]) on new Document() with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 445 fn.apply(obj, args); 446 }" did not throw 442 PASS EventTarget interface: calling removeEventListener(DOMString,EventListener,[object Object],[object Object]) on new Document() with too few arguments must throw TypeError 447 443 PASS EventTarget interface: new Document() must inherit property "dispatchEvent" with the proper type (2) 448 444 PASS EventTarget interface: calling dispatchEvent(Event) on new Document() with too few arguments must throw TypeError … … 608 604 PASS Node interface: calling removeChild(Node) on xmlDoc with too few arguments must throw TypeError 609 605 PASS EventTarget interface: xmlDoc must inherit property "addEventListener" with the proper type (0) 610 FAIL EventTarget interface: calling addEventListener(DOMString,EventListener,[object Object],[object Object]) on xmlDoc with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 611 fn.apply(obj, args); 612 }" did not throw 606 PASS EventTarget interface: calling addEventListener(DOMString,EventListener,[object Object],[object Object]) on xmlDoc with too few arguments must throw TypeError 613 607 PASS EventTarget interface: xmlDoc must inherit property "removeEventListener" with the proper type (1) 614 FAIL EventTarget interface: calling removeEventListener(DOMString,EventListener,[object Object],[object Object]) on xmlDoc with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 615 fn.apply(obj, args); 616 }" did not throw 608 PASS EventTarget interface: calling removeEventListener(DOMString,EventListener,[object Object],[object Object]) on xmlDoc with too few arguments must throw TypeError 617 609 PASS EventTarget interface: xmlDoc must inherit property "dispatchEvent" with the proper type (2) 618 610 PASS EventTarget interface: calling dispatchEvent(Event) on xmlDoc with too few arguments must throw TypeError … … 738 730 PASS Node interface: calling removeChild(Node) on document.doctype with too few arguments must throw TypeError 739 731 PASS EventTarget interface: document.doctype must inherit property "addEventListener" with the proper type (0) 740 FAIL EventTarget interface: calling addEventListener(DOMString,EventListener,[object Object],[object Object]) on document.doctype with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 741 fn.apply(obj, args); 742 }" did not throw 732 PASS EventTarget interface: calling addEventListener(DOMString,EventListener,[object Object],[object Object]) on document.doctype with too few arguments must throw TypeError 743 733 PASS EventTarget interface: document.doctype must inherit property "removeEventListener" with the proper type (1) 744 FAIL EventTarget interface: calling removeEventListener(DOMString,EventListener,[object Object],[object Object]) on document.doctype with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 745 fn.apply(obj, args); 746 }" did not throw 734 PASS EventTarget interface: calling removeEventListener(DOMString,EventListener,[object Object],[object Object]) on document.doctype with too few arguments must throw TypeError 747 735 PASS EventTarget interface: document.doctype must inherit property "dispatchEvent" with the proper type (2) 748 736 PASS EventTarget interface: calling dispatchEvent(Event) on document.doctype with too few arguments must throw TypeError … … 854 842 PASS Node interface: calling removeChild(Node) on document.createDocumentFragment() with too few arguments must throw TypeError 855 843 PASS EventTarget interface: document.createDocumentFragment() must inherit property "addEventListener" with the proper type (0) 856 FAIL EventTarget interface: calling addEventListener(DOMString,EventListener,[object Object],[object Object]) on document.createDocumentFragment() with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 857 fn.apply(obj, args); 858 }" did not throw 844 PASS EventTarget interface: calling addEventListener(DOMString,EventListener,[object Object],[object Object]) on document.createDocumentFragment() with too few arguments must throw TypeError 859 845 PASS EventTarget interface: document.createDocumentFragment() must inherit property "removeEventListener" with the proper type (1) 860 FAIL EventTarget interface: calling removeEventListener(DOMString,EventListener,[object Object],[object Object]) on document.createDocumentFragment() with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 861 fn.apply(obj, args); 862 }" did not throw 846 PASS EventTarget interface: calling removeEventListener(DOMString,EventListener,[object Object],[object Object]) on document.createDocumentFragment() with too few arguments must throw TypeError 863 847 PASS EventTarget interface: document.createDocumentFragment() must inherit property "dispatchEvent" with the proper type (2) 864 848 PASS EventTarget interface: calling dispatchEvent(Event) on document.createDocumentFragment() with too few arguments must throw TypeError … … 1101 1085 PASS Node interface: calling removeChild(Node) on element with too few arguments must throw TypeError 1102 1086 PASS EventTarget interface: element must inherit property "addEventListener" with the proper type (0) 1103 FAIL EventTarget interface: calling addEventListener(DOMString,EventListener,[object Object],[object Object]) on element with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 1104 fn.apply(obj, args); 1105 }" did not throw 1087 PASS EventTarget interface: calling addEventListener(DOMString,EventListener,[object Object],[object Object]) on element with too few arguments must throw TypeError 1106 1088 PASS EventTarget interface: element must inherit property "removeEventListener" with the proper type (1) 1107 FAIL EventTarget interface: calling removeEventListener(DOMString,EventListener,[object Object],[object Object]) on element with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 1108 fn.apply(obj, args); 1109 }" did not throw 1089 PASS EventTarget interface: calling removeEventListener(DOMString,EventListener,[object Object],[object Object]) on element with too few arguments must throw TypeError 1110 1090 PASS EventTarget interface: element must inherit property "dispatchEvent" with the proper type (2) 1111 1091 PASS EventTarget interface: calling dispatchEvent(Event) on element with too few arguments must throw TypeError … … 1282 1262 PASS Node interface: calling removeChild(Node) on document.createTextNode("abc") with too few arguments must throw TypeError 1283 1263 PASS EventTarget interface: document.createTextNode("abc") must inherit property "addEventListener" with the proper type (0) 1284 FAIL EventTarget interface: calling addEventListener(DOMString,EventListener,[object Object],[object Object]) on document.createTextNode("abc") with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 1285 fn.apply(obj, args); 1286 }" did not throw 1264 PASS EventTarget interface: calling addEventListener(DOMString,EventListener,[object Object],[object Object]) on document.createTextNode("abc") with too few arguments must throw TypeError 1287 1265 PASS EventTarget interface: document.createTextNode("abc") must inherit property "removeEventListener" with the proper type (1) 1288 FAIL EventTarget interface: calling removeEventListener(DOMString,EventListener,[object Object],[object Object]) on document.createTextNode("abc") with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 1289 fn.apply(obj, args); 1290 }" did not throw 1266 PASS EventTarget interface: calling removeEventListener(DOMString,EventListener,[object Object],[object Object]) on document.createTextNode("abc") with too few arguments must throw TypeError 1291 1267 PASS EventTarget interface: document.createTextNode("abc") must inherit property "dispatchEvent" with the proper type (2) 1292 1268 PASS EventTarget interface: calling dispatchEvent(Event) on document.createTextNode("abc") with too few arguments must throw TypeError … … 1396 1372 PASS Node interface: calling removeChild(Node) on xmlDoc.createProcessingInstruction("abc", "def") with too few arguments must throw TypeError 1397 1373 PASS EventTarget interface: xmlDoc.createProcessingInstruction("abc", "def") must inherit property "addEventListener" with the proper type (0) 1398 FAIL EventTarget interface: calling addEventListener(DOMString,EventListener,[object Object],[object Object]) on xmlDoc.createProcessingInstruction("abc", "def") with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 1399 fn.apply(obj, args); 1400 }" did not throw 1374 PASS EventTarget interface: calling addEventListener(DOMString,EventListener,[object Object],[object Object]) on xmlDoc.createProcessingInstruction("abc", "def") with too few arguments must throw TypeError 1401 1375 PASS EventTarget interface: xmlDoc.createProcessingInstruction("abc", "def") must inherit property "removeEventListener" with the proper type (1) 1402 FAIL EventTarget interface: calling removeEventListener(DOMString,EventListener,[object Object],[object Object]) on xmlDoc.createProcessingInstruction("abc", "def") with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 1403 fn.apply(obj, args); 1404 }" did not throw 1376 PASS EventTarget interface: calling removeEventListener(DOMString,EventListener,[object Object],[object Object]) on xmlDoc.createProcessingInstruction("abc", "def") with too few arguments must throw TypeError 1405 1377 PASS EventTarget interface: xmlDoc.createProcessingInstruction("abc", "def") must inherit property "dispatchEvent" with the proper type (2) 1406 1378 PASS EventTarget interface: calling dispatchEvent(Event) on xmlDoc.createProcessingInstruction("abc", "def") with too few arguments must throw TypeError … … 1508 1480 PASS Node interface: calling removeChild(Node) on document.createComment("abc") with too few arguments must throw TypeError 1509 1481 PASS EventTarget interface: document.createComment("abc") must inherit property "addEventListener" with the proper type (0) 1510 FAIL EventTarget interface: calling addEventListener(DOMString,EventListener,[object Object],[object Object]) on document.createComment("abc") with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 1511 fn.apply(obj, args); 1512 }" did not throw 1482 PASS EventTarget interface: calling addEventListener(DOMString,EventListener,[object Object],[object Object]) on document.createComment("abc") with too few arguments must throw TypeError 1513 1483 PASS EventTarget interface: document.createComment("abc") must inherit property "removeEventListener" with the proper type (1) 1514 FAIL EventTarget interface: calling removeEventListener(DOMString,EventListener,[object Object],[object Object]) on document.createComment("abc") with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 1515 fn.apply(obj, args); 1516 }" did not throw 1484 PASS EventTarget interface: calling removeEventListener(DOMString,EventListener,[object Object],[object Object]) on document.createComment("abc") with too few arguments must throw TypeError 1517 1485 PASS EventTarget interface: document.createComment("abc") must inherit property "dispatchEvent" with the proper type (2) 1518 1486 PASS EventTarget interface: calling dispatchEvent(Event) on document.createComment("abc") with too few arguments must throw TypeError -
trunk/LayoutTests/imported/w3c/web-platform-tests/html/dom/interfaces-expected.txt
r203333 r203377 419 419 PASS Node interface: calling removeChild(Node) on iframe.contentDocument with too few arguments must throw TypeError 420 420 PASS EventTarget interface: iframe.contentDocument must inherit property "addEventListener" with the proper type (0) 421 FAIL EventTarget interface: calling addEventListener(DOMString,EventListener,boolean) on iframe.contentDocument with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 422 fn.apply(obj, args); 423 }" did not throw 421 PASS EventTarget interface: calling addEventListener(DOMString,EventListener,boolean) on iframe.contentDocument with too few arguments must throw TypeError 424 422 PASS EventTarget interface: iframe.contentDocument must inherit property "removeEventListener" with the proper type (1) 425 FAIL EventTarget interface: calling removeEventListener(DOMString,EventListener,boolean) on iframe.contentDocument with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 426 fn.apply(obj, args); 427 }" did not throw 423 PASS EventTarget interface: calling removeEventListener(DOMString,EventListener,boolean) on iframe.contentDocument with too few arguments must throw TypeError 428 424 PASS EventTarget interface: iframe.contentDocument must inherit property "dispatchEvent" with the proper type (2) 429 425 PASS EventTarget interface: calling dispatchEvent(Event) on iframe.contentDocument with too few arguments must throw TypeError … … 725 721 PASS Node interface: calling removeChild(Node) on new Document() with too few arguments must throw TypeError 726 722 PASS EventTarget interface: new Document() must inherit property "addEventListener" with the proper type (0) 727 FAIL EventTarget interface: calling addEventListener(DOMString,EventListener,boolean) on new Document() with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 728 fn.apply(obj, args); 729 }" did not throw 723 PASS EventTarget interface: calling addEventListener(DOMString,EventListener,boolean) on new Document() with too few arguments must throw TypeError 730 724 PASS EventTarget interface: new Document() must inherit property "removeEventListener" with the proper type (1) 731 FAIL EventTarget interface: calling removeEventListener(DOMString,EventListener,boolean) on new Document() with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 732 fn.apply(obj, args); 733 }" did not throw 725 PASS EventTarget interface: calling removeEventListener(DOMString,EventListener,boolean) on new Document() with too few arguments must throw TypeError 734 726 PASS EventTarget interface: new Document() must inherit property "dispatchEvent" with the proper type (2) 735 727 PASS EventTarget interface: calling dispatchEvent(Event) on new Document() with too few arguments must throw TypeError … … 1034 1026 PASS Node interface: calling removeChild(Node) on document.implementation.createDocument(null, "", null) with too few arguments must throw TypeError 1035 1027 PASS EventTarget interface: document.implementation.createDocument(null, "", null) must inherit property "addEventListener" with the proper type (0) 1036 FAIL EventTarget interface: calling addEventListener(DOMString,EventListener,boolean) on document.implementation.createDocument(null, "", null) with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 1037 fn.apply(obj, args); 1038 }" did not throw 1028 PASS EventTarget interface: calling addEventListener(DOMString,EventListener,boolean) on document.implementation.createDocument(null, "", null) with too few arguments must throw TypeError 1039 1029 PASS EventTarget interface: document.implementation.createDocument(null, "", null) must inherit property "removeEventListener" with the proper type (1) 1040 FAIL EventTarget interface: calling removeEventListener(DOMString,EventListener,boolean) on document.implementation.createDocument(null, "", null) with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 1041 fn.apply(obj, args); 1042 }" did not throw 1030 PASS EventTarget interface: calling removeEventListener(DOMString,EventListener,boolean) on document.implementation.createDocument(null, "", null) with too few arguments must throw TypeError 1043 1031 PASS EventTarget interface: document.implementation.createDocument(null, "", null) must inherit property "dispatchEvent" with the proper type (2) 1044 1032 PASS EventTarget interface: calling dispatchEvent(Event) on document.implementation.createDocument(null, "", null) with too few arguments must throw TypeError … … 1466 1454 PASS Node interface: calling removeChild(Node) on document.createElement("noscript") with too few arguments must throw TypeError 1467 1455 PASS EventTarget interface: document.createElement("noscript") must inherit property "addEventListener" with the proper type (0) 1468 FAIL EventTarget interface: calling addEventListener(DOMString,EventListener,boolean) on document.createElement("noscript") with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 1469 fn.apply(obj, args); 1470 }" did not throw 1456 PASS EventTarget interface: calling addEventListener(DOMString,EventListener,boolean) on document.createElement("noscript") with too few arguments must throw TypeError 1471 1457 PASS EventTarget interface: document.createElement("noscript") must inherit property "removeEventListener" with the proper type (1) 1472 FAIL EventTarget interface: calling removeEventListener(DOMString,EventListener,boolean) on document.createElement("noscript") with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 1473 fn.apply(obj, args); 1474 }" did not throw 1458 PASS EventTarget interface: calling removeEventListener(DOMString,EventListener,boolean) on document.createElement("noscript") with too few arguments must throw TypeError 1475 1459 PASS EventTarget interface: document.createElement("noscript") must inherit property "dispatchEvent" with the proper type (2) 1476 1460 PASS EventTarget interface: calling dispatchEvent(Event) on document.createElement("noscript") with too few arguments must throw TypeError … … 2442 2426 FAIL MediaController interface: new MediaController() must inherit property "onvolumechange" with the proper type (28) assert_inherits: property "onvolumechange" not found in prototype chain 2443 2427 PASS EventTarget interface: new MediaController() must inherit property "addEventListener" with the proper type (0) 2444 FAIL EventTarget interface: calling addEventListener(DOMString,EventListener,boolean) on new MediaController() with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 2445 fn.apply(obj, args); 2446 }" did not throw 2428 PASS EventTarget interface: calling addEventListener(DOMString,EventListener,boolean) on new MediaController() with too few arguments must throw TypeError 2447 2429 PASS EventTarget interface: new MediaController() must inherit property "removeEventListener" with the proper type (1) 2448 FAIL EventTarget interface: calling removeEventListener(DOMString,EventListener,boolean) on new MediaController() with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 2449 fn.apply(obj, args); 2450 }" did not throw 2430 PASS EventTarget interface: calling removeEventListener(DOMString,EventListener,boolean) on new MediaController() with too few arguments must throw TypeError 2451 2431 PASS EventTarget interface: new MediaController() must inherit property "dispatchEvent" with the proper type (2) 2452 2432 PASS EventTarget interface: calling dispatchEvent(Event) on new MediaController() with too few arguments must throw TypeError … … 2470 2450 PASS TextTrackList interface: document.createElement("video").textTracks must inherit property "onremovetrack" with the proper type (5) 2471 2451 PASS EventTarget interface: document.createElement("video").textTracks must inherit property "addEventListener" with the proper type (0) 2472 FAIL EventTarget interface: calling addEventListener(DOMString,EventListener,boolean) on document.createElement("video").textTracks with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 2473 fn.apply(obj, args); 2474 }" did not throw 2452 PASS EventTarget interface: calling addEventListener(DOMString,EventListener,boolean) on document.createElement("video").textTracks with too few arguments must throw TypeError 2475 2453 PASS EventTarget interface: document.createElement("video").textTracks must inherit property "removeEventListener" with the proper type (1) 2476 FAIL EventTarget interface: calling removeEventListener(DOMString,EventListener,boolean) on document.createElement("video").textTracks with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 2477 fn.apply(obj, args); 2478 }" did not throw 2454 PASS EventTarget interface: calling removeEventListener(DOMString,EventListener,boolean) on document.createElement("video").textTracks with too few arguments must throw TypeError 2479 2455 PASS EventTarget interface: document.createElement("video").textTracks must inherit property "dispatchEvent" with the proper type (2) 2480 2456 PASS EventTarget interface: calling dispatchEvent(Event) on document.createElement("video").textTracks with too few arguments must throw TypeError … … 2515 2491 PASS TextTrack interface: document.createElement("track").track must inherit property "oncuechange" with the proper type (10) 2516 2492 PASS EventTarget interface: document.createElement("track").track must inherit property "addEventListener" with the proper type (0) 2517 FAIL EventTarget interface: calling addEventListener(DOMString,EventListener,boolean) on document.createElement("track").track with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 2518 fn.apply(obj, args); 2519 }" did not throw 2493 PASS EventTarget interface: calling addEventListener(DOMString,EventListener,boolean) on document.createElement("track").track with too few arguments must throw TypeError 2520 2494 PASS EventTarget interface: document.createElement("track").track must inherit property "removeEventListener" with the proper type (1) 2521 FAIL EventTarget interface: calling removeEventListener(DOMString,EventListener,boolean) on document.createElement("track").track with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 2522 fn.apply(obj, args); 2523 }" did not throw 2495 PASS EventTarget interface: calling removeEventListener(DOMString,EventListener,boolean) on document.createElement("track").track with too few arguments must throw TypeError 2524 2496 PASS EventTarget interface: document.createElement("track").track must inherit property "dispatchEvent" with the proper type (2) 2525 2497 PASS EventTarget interface: calling dispatchEvent(Event) on document.createElement("track").track with too few arguments must throw TypeError … … 5695 5667 PASS Window interface: window must inherit property "localStorage" with the proper type (124) 5696 5668 PASS EventTarget interface: window must inherit property "addEventListener" with the proper type (0) 5697 FAIL EventTarget interface: calling addEventListener(DOMString,EventListener,boolean) on window with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 5698 fn.apply(obj, args); 5699 }" did not throw 5669 PASS EventTarget interface: calling addEventListener(DOMString,EventListener,boolean) on window with too few arguments must throw TypeError 5700 5670 PASS EventTarget interface: window must inherit property "removeEventListener" with the proper type (1) 5701 FAIL EventTarget interface: calling removeEventListener(DOMString,EventListener,boolean) on window with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 5702 fn.apply(obj, args); 5703 }" did not throw 5671 PASS EventTarget interface: calling removeEventListener(DOMString,EventListener,boolean) on window with too few arguments must throw TypeError 5704 5672 PASS EventTarget interface: window must inherit property "dispatchEvent" with the proper type (2) 5705 5673 PASS EventTarget interface: calling dispatchEvent(Event) on window with too few arguments must throw TypeError … … 5860 5828 PASS ApplicationCache interface: window.applicationCache must inherit property "onobsolete" with the proper type (17) 5861 5829 PASS EventTarget interface: window.applicationCache must inherit property "addEventListener" with the proper type (0) 5862 FAIL EventTarget interface: calling addEventListener(DOMString,EventListener,boolean) on window.applicationCache with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 5863 fn.apply(obj, args); 5864 }" did not throw 5830 PASS EventTarget interface: calling addEventListener(DOMString,EventListener,boolean) on window.applicationCache with too few arguments must throw TypeError 5865 5831 PASS EventTarget interface: window.applicationCache must inherit property "removeEventListener" with the proper type (1) 5866 FAIL EventTarget interface: calling removeEventListener(DOMString,EventListener,boolean) on window.applicationCache with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 5867 fn.apply(obj, args); 5868 }" did not throw 5832 PASS EventTarget interface: calling removeEventListener(DOMString,EventListener,boolean) on window.applicationCache with too few arguments must throw TypeError 5869 5833 PASS EventTarget interface: window.applicationCache must inherit property "dispatchEvent" with the proper type (2) 5870 5834 PASS EventTarget interface: calling dispatchEvent(Event) on window.applicationCache with too few arguments must throw TypeError … … 6077 6041 PASS WebSocket interface: calling send(ArrayBufferView) on new WebSocket("ws://foo") with too few arguments must throw TypeError 6078 6042 PASS EventTarget interface: new WebSocket("ws://foo") must inherit property "addEventListener" with the proper type (0) 6079 FAIL EventTarget interface: calling addEventListener(DOMString,EventListener,boolean) on new WebSocket("ws://foo") with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 6080 fn.apply(obj, args); 6081 }" did not throw 6043 PASS EventTarget interface: calling addEventListener(DOMString,EventListener,boolean) on new WebSocket("ws://foo") with too few arguments must throw TypeError 6082 6044 PASS EventTarget interface: new WebSocket("ws://foo") must inherit property "removeEventListener" with the proper type (1) 6083 FAIL EventTarget interface: calling removeEventListener(DOMString,EventListener,boolean) on new WebSocket("ws://foo") with too few arguments must throw TypeError assert_throws: Called with 0 arguments function "function () { 6084 fn.apply(obj, args); 6085 }" did not throw 6045 PASS EventTarget interface: calling removeEventListener(DOMString,EventListener,boolean) on new WebSocket("ws://foo") with too few arguments must throw TypeError 6086 6046 PASS EventTarget interface: new WebSocket("ws://foo") must inherit property "dispatchEvent" with the proper type (2) 6087 6047 PASS EventTarget interface: calling dispatchEvent(Event) on new WebSocket("ws://foo") with too few arguments must throw TypeError -
trunk/LayoutTests/media/video-remote-control-playpause.html
r165916 r203377 132 132 video.addEventListener('pause', pause); 133 133 video.addEventListener('seeked', seeked); 134 video.addEventListener('ended');135 134 video.src = findMediaFile("video", "content/test"); 136 135 } -
trunk/Source/WebCore/ChangeLog
r203374 r203377 1 2016-07-18 Chris Dumez <cdumez@apple.com> 2 3 The 2 first parameters to addEventListener() / removeEventListener() should be mandatory 4 https://bugs.webkit.org/show_bug.cgi?id=158008 5 6 Reviewed by Darin Adler. 7 8 The 2 first parameters to addEventListener() / removeEventListener() should be 9 mandatory: 10 - https://dom.spec.whatwg.org/#interface-eventtarget 11 12 Firefox 46 and Chrome 50 both match the specification and throw an exception when those 13 parameters are omitted. However, those parameters were marked as optional in WebKit and 14 the calls were no-ops if those parameters were omitted. This patch aligns our behavior 15 with the specification and other browsers. 16 17 Test: fast/dom/eventtarget-api-parameters.html 18 19 * bindings/scripts/CodeGeneratorJS.pm: 20 (GetFunctionLength): Deleted. 21 * dom/EventTarget.idl: 22 1 23 2016-07-18 Brent Fulgham <bfulgham@apple.com> 2 24 -
trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm
r203222 r203377 1722 1722 { 1723 1723 my $function = shift; 1724 1725 # FIXME: EventTarget.addEventListener() / removeEventListener() currently specifies all the parameters as optional.1726 return 2 if $function->signature->name eq "addEventListener" || $function->signature->name eq "removeEventListener";1727 1724 1728 1725 my $length = 0; -
trunk/Source/WebCore/dom/EventTarget.idl
r201791 r203377 32 32 #endif 33 33 34 // FIXME: The 'type' and 'listener' parameters should not be optional. 35 [ObjCLegacyUnnamedParameters, ImplementedAs=addEventListenerForBindings] void addEventListener([AtomicString] optional DOMString type = "undefined", optional EventListener? listener, optional boolean useCapture = false); 36 [ObjCLegacyUnnamedParameters, ImplementedAs=removeEventListenerForBindings] void removeEventListener([AtomicString] optional DOMString type = "undefined", optional EventListener? listener, optional boolean useCapture = false); 34 [ObjCLegacyUnnamedParameters, ImplementedAs=addEventListenerForBindings] void addEventListener([AtomicString] DOMString type, EventListener? listener, optional boolean useCapture = false); 35 [ObjCLegacyUnnamedParameters, ImplementedAs=removeEventListenerForBindings] void removeEventListener([AtomicString] DOMString type, EventListener? listener, optional boolean useCapture = false); 37 36 38 37 // FIXME: event should not be nullable.
Note:
See TracChangeset
for help on using the changeset viewer.