Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(124)

Side by Side Diff: LayoutTests/fast/dom/MutationObserver/observe-characterdata.html

Issue 106773003: Make arguments to Document methods non-optional (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: rebase Created 7 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 <!DOCTYPE html> 1 <!DOCTYPE html>
2 <html> 2 <html>
3 <head> 3 <head>
4 <meta charset="utf-8"> 4 <meta charset="utf-8">
5 <script src="../../../resources/js-test.js"></script> 5 <script src="../../../resources/js-test.js"></script>
6 </head> 6 </head>
7 <body> 7 <body>
8 <p id=description></p> 8 <p id=description></p>
9 <div id="console"></div> 9 <div id="console"></div>
10 <script> 10 <script>
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
46 mutations = null; 46 mutations = null;
47 observer.disconnect(); 47 observer.disconnect();
48 charDataNode.textContent = 'baz'; 48 charDataNode.textContent = 'baz';
49 setTimeout(checkNotDeliveredAndMutateMultiple, 0); 49 setTimeout(checkNotDeliveredAndMutateMultiple, 0);
50 } 50 }
51 51
52 function checkNotDeliveredAndMutateMultiple() { 52 function checkNotDeliveredAndMutateMultiple() {
53 debug('...observer.disconnect() should prevent further delivery of mutat ions.'); 53 debug('...observer.disconnect() should prevent further delivery of mutat ions.');
54 54
55 shouldBe('mutations', 'null'); 55 shouldBe('mutations', 'null');
56 charDataNode = document.createComment(); 56 charDataNode = document.createComment('');
57 observer.observe(charDataNode, { characterData: true }); 57 observer.observe(charDataNode, { characterData: true });
58 charDataNode.textContent = 'foo'; 58 charDataNode.textContent = 'foo';
59 charDataNode.textContent = 'bar'; 59 charDataNode.textContent = 'bar';
60 setTimeout(finish); 60 setTimeout(finish);
61 } 61 }
62 62
63 function finish() { 63 function finish() {
64 debug('...re-observing after disconnect works with the same observer.'); 64 debug('...re-observing after disconnect works with the same observer.');
65 65
66 shouldBe('mutations.length', '2'); 66 shouldBe('mutations.length', '2');
(...skipping 248 matching lines...) Expand 10 before | Expand all | Expand 10 after
315 else 315 else
316 finishJSTest(); 316 finishJSTest();
317 } 317 }
318 318
319 description('Test WebKitMutationObserver.observe on CharacterData nodes'); 319 description('Test WebKitMutationObserver.observe on CharacterData nodes');
320 320
321 runNextTest(); 321 runNextTest();
322 </script> 322 </script>
323 </body> 323 </body>
324 </html> 324 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698