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

Side by Side Diff: LayoutTests/editing/deleting/delete-br-001.html

Issue 58533003: Move fast/js/resources files to resources. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years, 1 month 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 | Annotate | Revision Log
OLDNEW
1 <body> 1 <body>
2 <div id="container"> 2 <div id="container">
3 <div contenteditable="true" id="work"></div> 3 <div contenteditable="true" id="work"></div>
4 </div> 4 </div>
5 </div> 5 </div>
6 <script src="../../fast/js/resources/js-test-pre.js"></script> 6 <script src="../../resources/js-test.js"></script>
7 <script> 7 <script>
8 function $(id) { return document.getElementById(id); } 8 function $(id) { return document.getElementById(id); }
9 9
10 var sampleHTML = 'abc<br id="a"><br id="b"><br id="c">def'; 10 var sampleHTML = 'abc<br id="a"><br id="b"><br id="c">def';
11 var selection = window.getSelection(); 11 var selection = window.getSelection();
12 function testIt(nth, numberOfDeletes, expectedOffset, expectedHTML) { 12 function testIt(nth, numberOfDeletes, expectedOffset, expectedHTML) {
13 $('work').innerHTML = sampleHTML; 13 $('work').innerHTML = sampleHTML;
14 var range = document.createRange(); 14 var range = document.createRange();
15 range.setStartAfter($('work').querySelectorAll('br')[nth]); 15 range.setStartAfter($('work').querySelectorAll('br')[nth]);
16 selection.removeAllRanges(); 16 selection.removeAllRanges();
(...skipping 11 matching lines...) Expand all
28 testIt(1, 2, 3, 'abc<br id="c">def'); 28 testIt(1, 2, 3, 'abc<br id="c">def');
29 testIt(2, 2, 0, 'abc<br id="a">def'); 29 testIt(2, 2, 0, 'abc<br id="a">def');
30 testIt(2, 3, 3, 'abcdef'); 30 testIt(2, 3, 3, 'abcdef');
31 31
32 if (window.testRunner) 32 if (window.testRunner)
33 $('container').outerHTML = ''; 33 $('container').outerHTML = '';
34 else 34 else
35 $('work').innerHTML = sampleHTML; 35 $('work').innerHTML = sampleHTML;
36 </script> 36 </script>
37 </body> 37 </body>
OLDNEW
« no previous file with comments | « LayoutTests/editing/context-menu-leak-document.html ('k') | LayoutTests/editing/deleting/delete-br-after-image.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698