Move parseFontFaceDescriptor to CSSPropertyParser.cpp
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / fast / dom / Range / remove-twice-crash.html
blob2d3d2ac43b9b8a8f300c06b309b40fc384deae75
1 <div id="container">
2 <div id="sample">foo</div>
3 </div>
4 <script>
5 if (window.testRunner)
6 testRunner.dumpAsText();
8 function $(id) { return document.getElementById(id); }
10 var done = false;
11 document.addEventListener("DOMNodeRemovedFromDocument", function () {
12 if (done)
13 return;
14 done = true;
15 var beingRemoved = event.srcElement;
16 beingRemoved.parentNode.removeChild(beingRemoved);
17 }, true);
19 var range = document.createRange();
20 range.selectNode($('sample'));
22 try {
23 $('sample').parentNode.removeChild($('sample'));
24 } catch (e) {
25 // We get 'NotFoundError'.
28 $('container').outerHTML = 'PASS; NOT CRASHED';
29 </script>