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

Side by Side Diff: third_party/WebKit/PerformanceTests/Editing/delete-in-password-field.html

Issue 2730433004: Convert layout test password-delete-performance.html to performance test (Closed)
Patch Set: 2017-03-02T18:15:43 Change to PerfTestRunner.measureTime Created 3 years, 9 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 | « third_party/WebKit/LayoutTests/editing/deleting/password-delete-contents-expected.txt ('k') | no next file » | 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 <script src="../resources/runner.js"></script>
3 <div id="hidden" style="height:0px; overflow:hidden;"></div>
4 <input type="password">
5 <script>
6 const kCount = 1000;
7 const hidden = document.getElementById('hidden');
8 const password = document.querySelector('input[type=password]');
9
10 PerfTestRunner.measureTime({
11 description: 'Measures performance of delete in password field with many hidde n elements',
12 setup: () => {
13 password.focus();
14 hidden.innerHTML= '<p>foo bar</p>'.repeat(999);
yoichio 2017/03/03 02:07:22 This line can be before mesureTime?
yosin_UTC9 2017/03/03 09:07:12 Done.
15 },
16 run: () => {
17 for (let counter = 0; counter < kCount; ++counter) {
18 password.value = 'a';
yoichio 2017/03/03 02:07:22 In the setup, set password.value = 'abcdfef..." en
yosin_UTC9 2017/03/03 09:07:12 Done.
19 document.execCommand('delete');
20 }
21 },
22 });
23 </script>
OLDNEW
« no previous file with comments | « third_party/WebKit/LayoutTests/editing/deleting/password-delete-contents-expected.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698