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

Side by Side Diff: third_party/WebKit/LayoutTests/svg/dom/SVGLengthList-getItem.xhtml

Issue 2340733002: Convert LayoutTests/svg/dom/SVGLengthList*.html js-tests.js to testharness.js based tests (Closed)
Patch Set: Align with review comments Created 4 years, 3 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 <html xmlns="http://www.w3.org/1999/xhtml">
2 <head>
3 <script>window.enablePixelTesting = true;</script>
4 <script src="../../resources/js-test.js"></script>
5 </head>
6 <body>
7 <svg id="svg" xmlns="http://www.w3.org/2000/svg" width="200" height="200">
8 <text id="text1" x="50 100 150" y="50">ABC</text>
9 </svg>
10
11 <p id="description"></p>
12 <div id="console"></div>
13 <script type="text/javascript">
14 <![CDATA[
15 description("This is a test of the SVGLengthList::getItem() API.");
16
17 var svg = document.getElementById("svg");
18 var text1 = document.getElementById("text1");
19
20 debug("Check lengths of text x item lists");
21 shouldBe("text1.x.baseVal.numberOfItems", "3");
22
23 debug("");
24 debug("Test with various index parameters");
25 shouldThrow("text1.x.baseVal.getItem(-100)");
26 shouldThrow("text1.x.baseVal.getItem(-1)");
27 shouldBe("text1.x.baseVal.getItem(0).value", "50");
28 shouldBe("text1.x.baseVal.getItem(1).value", "100");
29 shouldBe("text1.x.baseVal.getItem(2).value", "150");
30 shouldThrow("text1.x.baseVal.getItem(3)");
31 shouldThrow("text1.x.baseVal.getItem(100)");
32
33 ]]>
34 </script>
35 </body>
36 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698