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

Side by Side Diff: third_party/WebKit/LayoutTests/fast/forms/select/select-remove-option-single.html

Issue 2372913002: fixed <select> element isn't updated after its single option removing. (Closed)
Patch Set: add layout test Created 4 years, 2 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
OLDNEW
(Empty)
1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
2 <html>
zino 2016/09/28 16:10:04 According to layout test style guide line[1], <htm
3 <head>
4
5 <script>
zino 2016/09/28 16:10:04 Please move this script block below <a></a>.
6
7 function load() {
zino 2016/09/28 16:10:04 You can simplify this script as follows: var rem
8 var select_ = document.getElementById("a");
9 select_.addEventListener('click', function() {
10 var option = document.getElementById("o");
11 option.remove();
12 });
13 select_.click();
14
15 }
16 window.onload = load;
17
18 </script>
19 <style type="text/css">
20 #s {
21 min-width: 100px;
22 }
23 </style>
24 <title>Test for HTMLSelectElement.remove() on an Options object</title>
25
26 </head>
27
28 <body>
29 <form>
zino 2016/09/28 16:10:04 This looks unnecessary.
30 <select id="s">
31 <option id="o" selected >hello</option>
32 </select>
33 <a id="a" herf="#" onload="test()">Remove option</a>
zino 2016/09/28 16:10:04 Let's remove 'onload' attribute as well.
34 </form>
35 <script>
zino 2016/09/28 16:10:04 This looks unnecessary.
36 </script>
37 </body>
38
39 </html>
40
41
42 <script>
43 if (window.testRunner)
zino 2016/09/28 16:10:04 You could do ref test instead of this pixel test.
44 window.testRunner.dumpAsTextWithPixelResults();
45 </script>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698