[GLIB] Unreviewed test gardening. Updated test expectations after r277896.
[WebKit-https.git] / LayoutTests / fast / attachment / attachment-select-on-click.html
1 <!DOCTYPE html><!-- webkit-test-runner [ AttachmentElementEnabled=true ] -->
2 <html>
3 <body onload="runTest()">
4 <div>text before <attachment id="attachment"></attachment> text after</div>
5 <div id="result"></div>
6 <script>
7 var file;
8 if (window.internals)
9     file = window.internals.createFile("resources/test-file.txt");
10
11 var attachment = document.getElementById('attachment');
12 attachment.file = file;
13
14 window.onload = function () {
15     if (!window.eventSender)
16         return;
17     eventSender.mouseMoveTo(attachment.offsetLeft + 10, attachment.offsetTop + 10);
18     eventSender.mouseDown(0);
19     eventSender.mouseUp(0);
20     var range = window.getSelection().getRangeAt(0);
21     document.getElementById("result").innerText = 'Start offset ' + range.startOffset + ' End offset ' + range.endOffset;
22 }
23 </script>
24 </body>
25 </html>