blob: d55dfd852bfd662358a4393ccbb6884a0da83885 [file] [log] [blame]
<!DOCTYPE html>
<html>
<body>
<p>This tests a bug when copying HTML markup inside &lt;pre&gt; tags. When pasted, this content would appear as the rendered form of that markup.
You should see markup in the editable region below. See &lt;rdar://5027857&gt;.</p>
<div><pre id="pre" contenteditable="true">&lt;input type='button'&gt;foo&lt;br&gt;bar&lt;b&gt;baz&lt;/b&gt;</pre></div>
<script src="../../resources/dump-as-markup.js"></script>
<script>
var pre = document.getElementById("pre");
pre.focus();
document.execCommand("SelectAll");
document.execCommand("Cut");
document.execCommand("Paste");
Markup.description(document.getElementsByTagName('p')[0].textContent);
Markup.dump(pre.parentNode);
</script>
</body>
</html>