Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / editing / pasteboard / copy-display-none.html
blobc1f928890dab0a516a780381f9febfa47897ce63
1 <head>
2 <script>
3 function runTest()
5 if (window.testRunner)
6 testRunner.dumpAsText();
7 var paragraph = document.getElementById("paragraph");
8 var textNode = paragraph.firstChild;
9 var range = document.createRange();
10 range.setStart(textNode, 24)
11 range.setEnd(textNode, 28)
12 getSelection().addRange(range);
13 paragraph.setAttribute("style", "display: none");
14 document.execCommand("Copy");
15 document.getElementById("message").firstChild.data = "PASSED";
17 </script>
18 </head>
19 <body onload="runTest()">
20 <p>This tests to make sure a copy after making the selection display: none does not hit an assertion.</p>
21 <p id="message">TEST NOT COMPLETE</p>
22 <div>This is text before the test paragraph. <p id="paragraph">This paragraph will be hidden and then copied.</p></div><p>This is the paragraph after the hidden one.</p>
23 </body>