Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / editing / deleting / whitespace-pre-1.html
blob7da24f71fb2fe9cee94311bbf6fc2ddeab523ddb
1 <script src="../../resources/dump-as-markup.js"></script>
2 <p id="description">This tests for a bug in endOfLine.</p>
4 <div id="test" contenteditable="true" style="white-space:pre;">You should not see this paragraph unless the command has been undone.
5 There should be three paragraphs in this editable region.
6 The first one should be empty.</div>
8 <script>
9 function runTestsOn(platform) {
10 var e = document.getElementById("test");
11 var s = window.getSelection();
13 if (window.internals)
14 internals.settings.setEditingBehavior(platform);
16 s.collapse(e, 0);
17 s.modify("extend", "forward", "lineBoundary");
18 document.execCommand("Delete");
19 Markup.dump("test", "on " + platform);
20 document.execCommand("undo");
21 Markup.dump("test", "after undo on " + platform);
24 if (window.testRunner)
25 testRunner.dumpEditingCallbacks();
26 Markup.description(description.textContent);
27 Markup.dump("test", "initial state");
28 runTestsOn("mac");
29 runTestsOn("win");
30 runTestsOn("unix");
31 runTestsOn("android");
32 </script>