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

Side by Side Diff: third_party/WebKit/LayoutTests/fast/forms/search/search-change-type-onsearch.html

Issue 1577243002: setRangeText shouldn't dispatch 'search' event. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 11 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/fast/forms/search/search-setrangetext-noevents.html » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 <!DOCTYPE html> 1 <!DOCTYPE html>
2 <body> 2 <body>
3 <script src="../../../resources/testharness.js"></script> 3 <script src="../../../resources/testharness.js"></script>
4 <script src="../../../resources/testharnessreport.js"></script> 4 <script src="../../../resources/testharnessreport.js"></script>
5 <div id="log"></div> 5 <div id="log"></div>
6 <input type="search" incremental> 6 <input type="search" incremental>
7 <script> 7 <script>
8 var input = document.querySelector('input'); 8 var input = document.querySelector('input');
9 input.onsearch = function() { 9 input.onsearch = function() {
10 input.type = 'text'; 10 input.type = 'text';
11 test.done();
11 }; 12 };
12 13
13 var test = async_test('Changing the input type in search event handler should no t crash.'); 14 var test = async_test('Changing the input type in search event handler should no t crash.');
14 test.step(function() { 15 test.step(function() {
15 input.offsetTop; 16 input.focus();
16 input.setRangeText('', 0, 1); // Trigger 'search' event. 17 eventSender.keyDown('a'); // Trigger 'search' event.
17 }); 18 });
18 setTimeout(function() { test.step(function() {
19 assert_equals(input.type, 'text');
20 test.done();
21 })}, 0);
22 </script> 19 </script>
23 </body> 20 </body>
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/fast/forms/search/search-setrangetext-noevents.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698