chromium/third_party/blink/web_tests/editing/selection/caret-and-focus-ring.html

<html>
<head>
<script>
if (window.testRunner) {
    testRunner.dumpEditingCallbacks();
    testRunner.dumpAsLayoutWithPixelResults();
}
</script>


<script>

function runTest() {
    if (window.testRunner) {
        testRunner.setWindowFocus(false);
        testRunner.setMainFrameIsFirstResponder(false);
    }
    var s = window.getSelection();
    var e = document.getElementById("test");
    
    e.focus();
    s.setBaseAndExtent(e, 0, e, 0);
}
</script>

<title>Caret and Focus Halo</title> 
</head>
<body>
<p>This tests that the caret and the focus halo are not displayed when the WebView is not focused (using the pixel output from DumpRenderTree).</p>
<div id="editme" contenteditable="true">This is an <span id="test">editable</span> region. No caret or focus ring should appear in the pixel results.</div>

<script>runTest();</script>

</body>
</html>