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

Unified Diff: LayoutTests/fast/dom/MutationObserver/mutation-record-constructor.html

Issue 13861028: Expose MutationRecord on DOMWindow (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years, 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | LayoutTests/fast/dom/MutationObserver/mutation-record-constructor-expected.txt » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: LayoutTests/fast/dom/MutationObserver/mutation-record-constructor.html
diff --git a/LayoutTests/fast/dom/MutationObserver/mutation-record-constructor.html b/LayoutTests/fast/dom/MutationObserver/mutation-record-constructor.html
new file mode 100644
index 0000000000000000000000000000000000000000..34156c6905d49340568af90a19e2b32ff8c95088
--- /dev/null
+++ b/LayoutTests/fast/dom/MutationObserver/mutation-record-constructor.html
@@ -0,0 +1,17 @@
+<!DOCTYPE html>
+<script src="../../js/resources/js-test-pre.js"></script>
+<script>
+description('MutationRecord should be exposed on window but not constructable');
+
+shouldBeNonNull('window.MutationRecord');
+shouldBe('typeof MutationRecord', '"function"');
+shouldThrow('new MutationRecord');
+
+var div = document.createElement('div');
+var observer = new MutationObserver(function(){});
+observer.observe(div, {attributes: true});
+div.id = 'foo';
+var record = observer.takeRecords()[0];
+shouldBeTrue('record instanceof MutationRecord');
+</script>
+<script src="../../js/resources/js-test-post.js"></script>
« no previous file with comments | « no previous file | LayoutTests/fast/dom/MutationObserver/mutation-record-constructor-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698