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

Side by Side Diff: LayoutTests/fast/dom/HTMLTableElement/insertRow-default-argument.html

Issue 270213007: HTMLTableElement.insertRow()'s argument default value should be -1 (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 7 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | LayoutTests/fast/dom/HTMLTableElement/insertRow-default-argument-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 <link rel="help" href="http://www.whatwg.org/specs/web-apps/current-work/multipa ge/tabular-data.html#htmltableelement">
5 <script src="../../../resources/js-test.js"></script>
6 </head>
7 <body>
8 <script>
9 description("Tests that HTMLTableElement.insertRow()'s default argument is -1.") ;
10
11 var table = document.createElement("table");
12 shouldBe("table.__proto__", "HTMLTableElement.prototype");
13
14 table.insertRow().innerHTML = "1"; // Should append.
15 table.insertRow().innerHTML = "2"; // Should append.
16 table.insertRow(-1).innerHTML = "3"; // Should append.
17 table.insertRow(0).innerHTML = "0"; // Should prepend.
18
19 var rows = table.rows;
20 shouldBe("rows.length", "4");
21 shouldBeEqualToString("rows[0].innerHTML", "0");
22 shouldBeEqualToString("rows[1].innerHTML", "1");
23 shouldBeEqualToString("rows[2].innerHTML", "2");
24 shouldBeEqualToString("rows[3].innerHTML", "3");
25 </script>
26 </body>
27 </html>
OLDNEW
« no previous file with comments | « no previous file | LayoutTests/fast/dom/HTMLTableElement/insertRow-default-argument-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698