summaryrefslogtreecommitdiffstats
path: root/third_party/WebKit/LayoutTests/editing/execCommand/justify-right-crash.html
blob: 26059ef5059df0dae905a0913a1a7b819fc2003a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
<!DOCTYPE html>
<html>
<head>
<script>
if (window.testRunner)
    testRunner.dumpAsText();

onload = function() {
    // Insert "body" element into "div" element. Simple repetition of "body"
    // element or renaming "body" to "div" doesn't reproduce bug.
    var targetNode = document.getElementById('target');
    targetNode.appendChild(document.body.cloneNode(true));

    document.designMode = 'on';
    document.execCommand('SelectAll');
    document.execCommand('JustifyRight');
    document.body.textContent = 'PASS if Blink doesn\'t crash.';
};
</script>
</head>
<body>
<textarea></textarea>
<span></span>
<div id="target" style="display:inline-table">foo</div>
</body>
</html>