Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(38)

Side by Side Diff: third_party/WebKit/LayoutTests/editing/execCommand/move-up-down-should-skip-hidden-elements.html

Issue 2689183003: Convert layout test move-up-down-should-skip-hidden-elements.html to performance test (Closed)
Patch Set: 2017-02-14T13:13:29 Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/editing/execCommand/move-up-down-should-skip-hidden-elements-expected.txt » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 <!DOCTYPE html>
2 <html>
3 <head>
4 <script src="../../resources/js-test.js"></script>
5 <title>Test moving up and down through non-renderered elements.</title>
6 </head>
7 <body>
8 <div id="before" hidden></div>
9 <h1 id="first_line">First line of rendered text</h1>
10 <div id="after" hidden></div>
11
12 <p id="description"></p>
13 <div id="console"></div>
14
15 <script>
16 description("Test moving up and down through non-renderered elements. This test should execute quickly if it's working correctly; a timeout is a failure.");
17
18 var before = document.getElementById("before");
19 var after = document.getElementById("after");
20 for (var i = 0; i < 1000; i++) {
21 before.appendChild(document.createElement("meta"));
22 after.appendChild(document.createElement("meta"));
23 }
24
25 function selectFirstLine() {
26 var selection = document.getSelection();
27 selection.removeAllRanges();
28 var range = document.createRange();
29 range.selectNode(document.getElementById("first_line"));
30 selection.addRange(range);
31 }
32
33 for (var i = 0; i < 100; i++) {
34 selectFirstLine();
35 if (window.testRunner)
36 testRunner.execCommand("MoveUpAndModifySelection");
37
38 selectFirstLine();
39 if (window.testRunner)
40 testRunner.execCommand("MoveDownAndModifySelection");
41 }
42
43 before.textContent = "";
44 after.textContent = "";
45
46 </script>
47 </body>
48 </html>
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/editing/execCommand/move-up-down-should-skip-hidden-elements-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698