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

Side by Side Diff: LayoutTests/fast/dom/MutationObserver/mutation-record-nullity.html

Issue 12317072: Merge 143386 (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/1410/
Patch Set: Created 7 years, 10 months 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
OLDNEW
1 <!DOCTYPE html> 1 <!DOCTYPE html>
2 <script src="../../js/resources/js-test-pre.js"></script> 2 <script src="../../js/resources/js-test-pre.js"></script>
3 <script> 3 <script>
4 description('Non-relevant properties on mutation records should be null, except for NodeLists, which should be empty'); 4 description('Non-relevant properties on mutation records should be null, except for NodeLists, which should be empty');
5 var observer = new WebKitMutationObserver(function() {}); 5 var observer = new MutationObserver(function() {});
6 6
7 var text = document.createTextNode('something'); 7 var text = document.createTextNode('something');
8 observer.observe(text, {characterData: true}); 8 observer.observe(text, {characterData: true});
9 text.data = 'something else'; 9 text.data = 'something else';
10 var record = observer.takeRecords()[0]; 10 var record = observer.takeRecords()[0];
11 debug('characterData record:'); 11 debug('characterData record:');
12 shouldBeNull('record.attributeName'); 12 shouldBeNull('record.attributeName');
13 shouldBeNull('record.attributeNamespace'); 13 shouldBeNull('record.attributeNamespace');
14 shouldBeNull('record.oldValue'); 14 shouldBeNull('record.oldValue');
15 shouldBeNull('record.previousSibling'); 15 shouldBeNull('record.previousSibling');
(...skipping 15 matching lines...) Expand all
31 record = observer.takeRecords()[0]; 31 record = observer.takeRecords()[0];
32 debug('\nattributes record:'); 32 debug('\nattributes record:');
33 shouldBeNull('record.attributeNamespace'); 33 shouldBeNull('record.attributeNamespace');
34 shouldBeNull('record.oldValue'); 34 shouldBeNull('record.oldValue');
35 shouldBeNull('record.previousSibling'); 35 shouldBeNull('record.previousSibling');
36 shouldBeNull('record.nextSibling'); 36 shouldBeNull('record.nextSibling');
37 shouldBe('record.addedNodes.length', '0'); 37 shouldBe('record.addedNodes.length', '0');
38 shouldBe('record.removedNodes.length', '0'); 38 shouldBe('record.removedNodes.length', '0');
39 </script> 39 </script>
40 <script src="../../js/resources/js-test-post.js"></script> 40 <script src="../../js/resources/js-test-post.js"></script>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698