OLD | NEW |
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 Loading... |
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> |
OLD | NEW |