| Index: LayoutTests/editing/inserting/insert-with-mutation-event.html
|
| diff --git a/LayoutTests/editing/inserting/insert-with-mutation-event.html b/LayoutTests/editing/inserting/insert-with-mutation-event.html
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..e4c5d97174b3fa2806659e4c8e65a4257a7cf688
|
| --- /dev/null
|
| +++ b/LayoutTests/editing/inserting/insert-with-mutation-event.html
|
| @@ -0,0 +1,22 @@
|
| +<!DOCTYPE html>
|
| +<body>
|
| +<div id="sample" contenteditable="true">
|
| +foo
|
| +<div id="test" style="font-weight:bold">bar</div>
|
| +</div>
|
| +</body>
|
| +<script>
|
| +if (window.testRunner)
|
| + testRunner.dumpAsText();
|
| +function $(id) { return document.getElementById(id); }
|
| +window.getSelection().collapse($('test'), 0);
|
| +document.execCommand('Delete');
|
| +var sample = $('sample');
|
| +sample.addEventListener('DOMSubtreeModified', function () {
|
| + // Move nodes being processed by 'InsertText' to another document.
|
| + var anotherDoc = document.implementation.createDocument('', null);
|
| + anotherDoc.adoptNode(sample);
|
| +});
|
| +document.execCommand('InsertText', false, 'ab123cd');
|
| +document.body.textContent = 'PASS; NOT CRASHED';
|
| +</script>
|
|
|