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

Side by Side Diff: third_party/WebKit/LayoutTests/svg/dom/SVGLength-px-with-context-expected.txt

Issue 2271223002: Convert LayoutTests/svg/dom/SVGLength*.html js-tests.js tests to testharness.js based tests. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: moved length to local 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 This test checks SVGLength - converting from px to all other unit types
2
3 On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE ".
4
5
6
7 Set value to be 2px
8 PASS length.unitType is SVGLength.SVG_LENGTHTYPE_PX
9 PASS length.value is 2
10 PASS length.valueInSpecifiedUnits is 2
11 PASS length.valueAsString is "2px"
12
13 Convert from px to unitless
14 PASS length.convertToSpecifiedUnits(SVGLength.SVG_LENGTHTYPE_NUMBER) is undefine d.
15 PASS length.valueAsString is "2"
16 PASS length.value is 2
17 PASS length.valueInSpecifiedUnits is 2
18 PASS length.unitType is SVGLength.SVG_LENGTHTYPE_NUMBER
19
20 Reset to 2px
21
22 Convert from px to percentage
23 PASS length.convertToSpecifiedUnits(SVGLength.SVG_LENGTHTYPE_PERCENTAGE) is unde fined.
24 PASS length.valueAsString is "1.33333%"
25 PASS length.valueInSpecifiedUnits.toFixed(5) is "1.33333"
26 PASS length.value.toFixed(1) is "2.0"
27 PASS length.unitType is SVGLength.SVG_LENGTHTYPE_PERCENTAGE
28
29 Reset to 2px
30
31 Convert from px to ems
32 PASS length.convertToSpecifiedUnits(SVGLength.SVG_LENGTHTYPE_EMS) is undefined.
33 PASS length.valueAsString is "0.166667em"
34 PASS length.valueInSpecifiedUnits.toFixed(6) is "0.166667"
35 PASS length.value.toFixed(1) is "2.0"
36 PASS length.unitType is SVGLength.SVG_LENGTHTYPE_EMS
37
38 Reset to 2px
39
40 Convert from px to exs
41 PASS length.convertToSpecifiedUnits(SVGLength.SVG_LENGTHTYPE_EXS) is undefined.
42 PASS length.valueInSpecifiedUnits.toFixed(1) is "0.2"
43 PASS length.value.toFixed(1) is "2.0"
44 PASS length.unitType is SVGLength.SVG_LENGTHTYPE_EXS
45
46 Reset to 2px
47
48 Convert from px to cm
49 PASS length.convertToSpecifiedUnits(SVGLength.SVG_LENGTHTYPE_CM) is undefined.
50 PASS length.valueAsString is "0.0529167cm"
51 PASS length.valueInSpecifiedUnits.toFixed(7) is "0.0529167"
52 PASS length.value.toFixed(1) is "2.0"
53 PASS length.unitType is SVGLength.SVG_LENGTHTYPE_CM
54
55 Reset to 2px
56
57 Convert from px to mm
58 PASS length.convertToSpecifiedUnits(SVGLength.SVG_LENGTHTYPE_MM) is undefined.
59 PASS length.valueAsString is "0.529167mm"
60 PASS length.valueInSpecifiedUnits.toFixed(6) is "0.529167"
61 PASS length.value.toFixed(1) is "2.0"
62 PASS length.unitType is SVGLength.SVG_LENGTHTYPE_MM
63
64 Reset to 2px
65
66 Convert from px to in
67 PASS length.convertToSpecifiedUnits(SVGLength.SVG_LENGTHTYPE_IN) is undefined.
68 PASS length.valueAsString is "0.0208333in"
69 PASS length.valueInSpecifiedUnits.toFixed(7) is "0.0208333"
70 PASS length.value.toFixed(1) is "2.0"
71 PASS length.unitType is SVGLength.SVG_LENGTHTYPE_IN
72
73 Reset to 2px
74
75 Convert from px to pt
76 PASS length.convertToSpecifiedUnits(SVGLength.SVG_LENGTHTYPE_PT) is undefined.
77 PASS length.valueAsString is "1.5pt"
78 PASS length.valueInSpecifiedUnits is 1.5
79 PASS length.value.toFixed(1) is "2.0"
80 PASS length.unitType is SVGLength.SVG_LENGTHTYPE_PT
81
82 Reset to 2px
83
84 Convert from px to pc
85 PASS length.convertToSpecifiedUnits(SVGLength.SVG_LENGTHTYPE_PC) is undefined.
86 PASS length.valueInSpecifiedUnits.toFixed(3) is "0.125"
87 PASS length.value.toFixed(1) is "2.0"
88 PASS length.unitType is SVGLength.SVG_LENGTHTYPE_PC
89 PASS successfullyParsed is true
90
91 TEST COMPLETE
92
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698