Index: LayoutTests/fast/dom/document-set-title-single-DOMSubtreeModified.html |
diff --git a/LayoutTests/fast/dom/document-set-title-single-DOMSubtreeModified.html b/LayoutTests/fast/dom/document-set-title-single-DOMSubtreeModified.html |
new file mode 100644 |
index 0000000000000000000000000000000000000000..509a32bd9bde7784665072d81667c8b4f44d2ed5 |
--- /dev/null |
+++ b/LayoutTests/fast/dom/document-set-title-single-DOMSubtreeModified.html |
@@ -0,0 +1,15 @@ |
+<!DOCTYPE html> |
+<title>document title and DOMSubtreeModified</title> |
+<script src="../../resources/js-test.js"></script> |
+<body> |
+<script> |
+ description("On setting document.title, only one DOMSubtreeModified event is created."); |
+ |
+ var titleElement = document.documentElement.firstChild.firstChild; |
+ var i=0; |
+ titleElement.addEventListener('DOMSubtreeModified', function() { i++; }); |
+ document.title = "new"; |
+ shouldBeEqualToString("document.title", "new"); |
+ shouldBeTrue("i == 1"); |
+</script> |
+</body> |