Index: LayoutTests/fast/dom/shadow/event-path.html |
diff --git a/LayoutTests/fast/dom/shadow/event-path.html b/LayoutTests/fast/dom/shadow/event-path.html |
new file mode 100644 |
index 0000000000000000000000000000000000000000..b8ff94535e6cf7dbbe7fad766c8cf681b0b5b763 |
--- /dev/null |
+++ b/LayoutTests/fast/dom/shadow/event-path.html |
@@ -0,0 +1,32 @@ |
+<!DOCTYPE html> |
+<html> |
+<head> |
+<script src="../../js/resources/js-test-pre.js"></script> |
+<script src="resources/shadow-dom.js"></script> |
+</head> |
+<body> |
+<p id="description"></p> |
+<div id="sandbox"></div> |
+<pre id="console"></pre> |
+<div id='a'> |
+ <div id='b'> |
+ <div id='c'> |
+ </div> |
+ </div> |
+</div> |
+<script> |
+var b = document.getElementById('b'); |
+b.addEventListener('click', function(event) { |
+ var path = event.path(); |
+ debug(dumpNodeList(path)); |
+ debug('Makes sure that event.path() returns static NodeList.'); |
+ path[1] = ''; |
+ debug(dumpNodeList(event.path())); |
+}); |
+var clickEvent = document.createEvent("MouseEvents"); |
+clickEvent.initMouseEvent('click', true, false, window, 0, 0, 0, 0, 0, false, false, false, false, 0, null); |
+b.dispatchEvent(clickEvent); |
+</script> |
+<script src="../../js/resources/js-test-post.js"></script> |
+</body> |
+</html> |