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

Side by Side Diff: third_party/WebKit/LayoutTests/svg/dom/script-tests/SVGAnimatedNumberList.js

Issue 2713833002: Convert LayoutTests/svg/dom/SVGAnimated*.html js-tests.js to testharness.js based tests. (Closed)
Patch Set: 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/svg/dom/script-tests/SVGAnimatedNumber.js ('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 description("This test checks the SVGAnimatedNumberList API - utilizing the rota te property of SVGTextElement");
2
3 var textElement = document.createElementNS("http://www.w3.org/2000/svg", "text") ;
4 textElement.setAttribute("rotate", "50");
5
6 debug("");
7 debug("Check initial rotate value");
8 shouldBeEqualToString("textElement.rotate.toString()", "[object SVGAnimatedNumbe rList]");
9 shouldBeEqualToString("textElement.rotate.baseVal.toString()", "[object SVGNumbe rList]");
10 shouldBe("textElement.rotate.baseVal.getItem(0).value", "50");
11
12 debug("");
13 debug("Check that number lists are dynamic, caching value in a local variable an d modifying it, should take effect");
14 var numRef = textElement.rotate.baseVal;
15 numRef.getItem(0).value = 100;
16 shouldBe("numRef.getItem(0).value", "100");
17 shouldBe("textElement.rotate.baseVal.getItem(0).value", "100");
18
19 debug("");
20 debug("Check that assigning to baseVal has no effect, as no setter is defined");
21 shouldBe("textElement.rotate.baseVal = -1", "-1");
22 shouldBeEqualToString("textElement.rotate.baseVal = 'aString'", "aString");
23 shouldBe("textElement.rotate.baseVal = textElement", "textElement");
24
25 debug("");
26 debug("Check that the rotate value remained 100, and the baseVal type has not be en changed");
27 shouldBeEqualToString("textElement.rotate.baseVal.toString()", "[object SVGNumbe rList]");
28 shouldBe("textElement.rotate.baseVal.getItem(0).value", "100");
29
30 successfullyParsed = true;
OLDNEW
« no previous file with comments | « third_party/WebKit/LayoutTests/svg/dom/script-tests/SVGAnimatedNumber.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698