OLD | NEW |
| (Empty) |
1 This test checks the SVGTransform API | |
2 | |
3 On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE
". | |
4 | |
5 | |
6 | |
7 Check initial transform values | |
8 PASS transform.type is SVGTransform.SVG_TRANSFORM_MATRIX | |
9 PASS transform.angle is 0 | |
10 PASS transform.matrix.a is 1 | |
11 PASS transform.matrix.b is 0 | |
12 PASS transform.matrix.c is 0 | |
13 PASS transform.matrix.d is 1 | |
14 PASS transform.matrix.e is 0 | |
15 PASS transform.matrix.f is 0 | |
16 | |
17 Change to skewX transformation | |
18 PASS transform.setSkewX(45) is undefined. | |
19 PASS transform.type is SVGTransform.SVG_TRANSFORM_SKEWX | |
20 PASS transform.angle is 45 | |
21 PASS transform.matrix.a is 1 | |
22 PASS transform.matrix.b is 0 | |
23 PASS transform.matrix.c.toFixed(1) is "1.0" | |
24 PASS transform.matrix.d is 1 | |
25 PASS transform.matrix.e is 0 | |
26 PASS transform.matrix.f is 0 | |
27 | |
28 Changing matrix.e to 100, should reset transformation type to MATRIX, and angle
should be 0 | |
29 PASS transform.matrix.e = 100 is 100 | |
30 PASS transform.type is SVGTransform.SVG_TRANSFORM_MATRIX | |
31 PASS transform.angle is 0 | |
32 PASS transform.matrix.a is 1 | |
33 PASS transform.matrix.b is 0 | |
34 PASS transform.matrix.c.toFixed(1) is "1.0" | |
35 PASS transform.matrix.d is 1 | |
36 PASS transform.matrix.e is 100 | |
37 PASS transform.matrix.f is 0 | |
38 | |
39 Now revert to initial matrix | |
40 PASS transform.matrix.c = null is null | |
41 PASS transform.matrix.e = 0 is 0 | |
42 PASS transform.type is SVGTransform.SVG_TRANSFORM_MATRIX | |
43 PASS transform.angle is 0 | |
44 PASS transform.matrix.a is 1 | |
45 PASS transform.matrix.b is 0 | |
46 PASS transform.matrix.c is 0 | |
47 PASS transform.matrix.d is 1 | |
48 PASS transform.matrix.e is 0 | |
49 PASS transform.matrix.f is 0 | |
50 | |
51 Check passing invalid arguments to 'setMatrix' | |
52 PASS transform.setMatrix() threw exception TypeError: Failed to execute 'setMatr
ix' on 'SVGTransform': 1 argument required, but only 0 present.. | |
53 PASS transform.setMatrix(transform) threw exception TypeError: Failed to execute
'setMatrix' on 'SVGTransform': parameter 1 is not of type 'SVGMatrix'.. | |
54 PASS transform.setMatrix(svgElement) threw exception TypeError: Failed to execut
e 'setMatrix' on 'SVGTransform': parameter 1 is not of type 'SVGMatrix'.. | |
55 PASS transform.setMatrix('aString') threw exception TypeError: Failed to execute
'setMatrix' on 'SVGTransform': parameter 1 is not of type 'SVGMatrix'.. | |
56 PASS transform.setMatrix(1) threw exception TypeError: Failed to execute 'setMat
rix' on 'SVGTransform': parameter 1 is not of type 'SVGMatrix'.. | |
57 PASS transform.setMatrix(false) threw exception TypeError: Failed to execute 'se
tMatrix' on 'SVGTransform': parameter 1 is not of type 'SVGMatrix'.. | |
58 | |
59 Check passing invalid arguments to 'setTranslate' | |
60 PASS transform.setTranslate() threw exception TypeError: Failed to execute 'setT
ranslate' on 'SVGTransform': 2 arguments required, but only 0 present.. | |
61 PASS transform.setTranslate(transform) threw exception TypeError: Failed to exec
ute 'setTranslate' on 'SVGTransform': 2 arguments required, but only 1 present.. | |
62 PASS transform.setTranslate(svgElement) threw exception TypeError: Failed to exe
cute 'setTranslate' on 'SVGTransform': 2 arguments required, but only 1 present.
. | |
63 PASS transform.setTranslate('aString') threw exception TypeError: Failed to exec
ute 'setTranslate' on 'SVGTransform': 2 arguments required, but only 1 present.. | |
64 PASS transform.setTranslate(1, transform) threw exception TypeError: Failed to e
xecute 'setTranslate' on 'SVGTransform': The provided float value is non-finite.
. | |
65 PASS transform.setTranslate(1, svgElement) threw exception TypeError: Failed to
execute 'setTranslate' on 'SVGTransform': The provided float value is non-finite
.. | |
66 PASS transform.setTranslate(1, 'aString') threw exception TypeError: Failed to e
xecute 'setTranslate' on 'SVGTransform': The provided float value is non-finite.
. | |
67 PASS transform.setTranslate(transform, 1) threw exception TypeError: Failed to e
xecute 'setTranslate' on 'SVGTransform': The provided float value is non-finite.
. | |
68 PASS transform.setTranslate(svgElement, 1) threw exception TypeError: Failed to
execute 'setTranslate' on 'SVGTransform': The provided float value is non-finite
.. | |
69 PASS transform.setTranslate('aString', 1) threw exception TypeError: Failed to e
xecute 'setTranslate' on 'SVGTransform': The provided float value is non-finite.
. | |
70 PASS transform.setTranslate(transform, transform) threw exception TypeError: Fai
led to execute 'setTranslate' on 'SVGTransform': The provided float value is non
-finite.. | |
71 PASS transform.setTranslate(svgElement, svgElement) threw exception TypeError: F
ailed to execute 'setTranslate' on 'SVGTransform': The provided float value is n
on-finite.. | |
72 PASS transform.setTranslate('aString', 'aString') threw exception TypeError: Fai
led to execute 'setTranslate' on 'SVGTransform': The provided float value is non
-finite.. | |
73 PASS transform.setTranslate(NaN, 1) threw exception TypeError: Failed to execute
'setTranslate' on 'SVGTransform': The provided float value is non-finite.. | |
74 PASS transform.setTranslate(Infinity, 1) threw exception TypeError: Failed to ex
ecute 'setTranslate' on 'SVGTransform': The provided float value is non-finite.. | |
75 PASS transform.setTranslate(1, NaN) threw exception TypeError: Failed to execute
'setTranslate' on 'SVGTransform': The provided float value is non-finite.. | |
76 PASS transform.setTranslate(1, Infinity) threw exception TypeError: Failed to ex
ecute 'setTranslate' on 'SVGTransform': The provided float value is non-finite.. | |
77 | |
78 Check passing invalid arguments to 'setScale' | |
79 PASS transform.setScale() threw exception TypeError: Failed to execute 'setScale
' on 'SVGTransform': 2 arguments required, but only 0 present.. | |
80 PASS transform.setScale(transform) threw exception TypeError: Failed to execute
'setScale' on 'SVGTransform': 2 arguments required, but only 1 present.. | |
81 PASS transform.setScale(svgElement) threw exception TypeError: Failed to execute
'setScale' on 'SVGTransform': 2 arguments required, but only 1 present.. | |
82 PASS transform.setScale('aString') threw exception TypeError: Failed to execute
'setScale' on 'SVGTransform': 2 arguments required, but only 1 present.. | |
83 PASS transform.setScale(1, transform) threw exception TypeError: Failed to execu
te 'setScale' on 'SVGTransform': The provided float value is non-finite.. | |
84 PASS transform.setScale(1, svgElement) threw exception TypeError: Failed to exec
ute 'setScale' on 'SVGTransform': The provided float value is non-finite.. | |
85 PASS transform.setScale(1, 'aString') threw exception TypeError: Failed to execu
te 'setScale' on 'SVGTransform': The provided float value is non-finite.. | |
86 PASS transform.setScale(transform, 1) threw exception TypeError: Failed to execu
te 'setScale' on 'SVGTransform': The provided float value is non-finite.. | |
87 PASS transform.setScale(svgElement, 1) threw exception TypeError: Failed to exec
ute 'setScale' on 'SVGTransform': The provided float value is non-finite.. | |
88 PASS transform.setScale('aString', 1) threw exception TypeError: Failed to execu
te 'setScale' on 'SVGTransform': The provided float value is non-finite.. | |
89 PASS transform.setScale(transform, transform) threw exception TypeError: Failed
to execute 'setScale' on 'SVGTransform': The provided float value is non-finite.
. | |
90 PASS transform.setScale(svgElement, svgElement) threw exception TypeError: Faile
d to execute 'setScale' on 'SVGTransform': The provided float value is non-finit
e.. | |
91 PASS transform.setScale('aString', 'aString') threw exception TypeError: Failed
to execute 'setScale' on 'SVGTransform': The provided float value is non-finite.
. | |
92 PASS transform.setScale(NaN, 1) threw exception TypeError: Failed to execute 'se
tScale' on 'SVGTransform': The provided float value is non-finite.. | |
93 PASS transform.setScale(Infinity, 1) threw exception TypeError: Failed to execut
e 'setScale' on 'SVGTransform': The provided float value is non-finite.. | |
94 PASS transform.setScale(1, NaN) threw exception TypeError: Failed to execute 'se
tScale' on 'SVGTransform': The provided float value is non-finite.. | |
95 PASS transform.setScale(1, Infinity) threw exception TypeError: Failed to execut
e 'setScale' on 'SVGTransform': The provided float value is non-finite.. | |
96 | |
97 Check passing invalid arguments to 'setRotate' | |
98 PASS transform.setRotate() threw exception TypeError: Failed to execute 'setRota
te' on 'SVGTransform': 3 arguments required, but only 0 present.. | |
99 PASS transform.setRotate(transform) threw exception TypeError: Failed to execute
'setRotate' on 'SVGTransform': 3 arguments required, but only 1 present.. | |
100 PASS transform.setRotate(svgElement) threw exception TypeError: Failed to execut
e 'setRotate' on 'SVGTransform': 3 arguments required, but only 1 present.. | |
101 PASS transform.setRotate('aString') threw exception TypeError: Failed to execute
'setRotate' on 'SVGTransform': 3 arguments required, but only 1 present.. | |
102 PASS transform.setRotate(1, transform) threw exception TypeError: Failed to exec
ute 'setRotate' on 'SVGTransform': 3 arguments required, but only 2 present.. | |
103 PASS transform.setRotate(1, svgElement) threw exception TypeError: Failed to exe
cute 'setRotate' on 'SVGTransform': 3 arguments required, but only 2 present.. | |
104 PASS transform.setRotate(1, 'aString') threw exception TypeError: Failed to exec
ute 'setRotate' on 'SVGTransform': 3 arguments required, but only 2 present.. | |
105 PASS transform.setRotate(1, 1, transform) threw exception TypeError: Failed to e
xecute 'setRotate' on 'SVGTransform': The provided float value is non-finite.. | |
106 PASS transform.setRotate(1, 1, svgElement) threw exception TypeError: Failed to
execute 'setRotate' on 'SVGTransform': The provided float value is non-finite.. | |
107 PASS transform.setRotate(1, 1, 'aString') threw exception TypeError: Failed to e
xecute 'setRotate' on 'SVGTransform': The provided float value is non-finite.. | |
108 PASS transform.setRotate(NaN, 1, 1) threw exception TypeError: Failed to execute
'setRotate' on 'SVGTransform': The provided float value is non-finite.. | |
109 PASS transform.setRotate(Infinity, 1, 1) threw exception TypeError: Failed to ex
ecute 'setRotate' on 'SVGTransform': The provided float value is non-finite.. | |
110 PASS transform.setRotate(1, NaN, 1) threw exception TypeError: Failed to execute
'setRotate' on 'SVGTransform': The provided float value is non-finite.. | |
111 PASS transform.setRotate(1, Infinity, 1) threw exception TypeError: Failed to ex
ecute 'setRotate' on 'SVGTransform': The provided float value is non-finite.. | |
112 PASS transform.setRotate(1, 1, NaN) threw exception TypeError: Failed to execute
'setRotate' on 'SVGTransform': The provided float value is non-finite.. | |
113 PASS transform.setRotate(1, 1, Infinity) threw exception TypeError: Failed to ex
ecute 'setRotate' on 'SVGTransform': The provided float value is non-finite.. | |
114 | |
115 Check passing invalid arguments to 'setSkewX' | |
116 PASS transform.setSkewX() threw exception TypeError: Failed to execute 'setSkewX
' on 'SVGTransform': 1 argument required, but only 0 present.. | |
117 PASS transform.setSkewX(transform) threw exception TypeError: Failed to execute
'setSkewX' on 'SVGTransform': The provided float value is non-finite.. | |
118 PASS transform.setSkewX(svgElement) threw exception TypeError: Failed to execute
'setSkewX' on 'SVGTransform': The provided float value is non-finite.. | |
119 PASS transform.setSkewX('aString') threw exception TypeError: Failed to execute
'setSkewX' on 'SVGTransform': The provided float value is non-finite.. | |
120 PASS transform.setSkewX(NaN) threw exception TypeError: Failed to execute 'setSk
ewX' on 'SVGTransform': The provided float value is non-finite.. | |
121 PASS transform.setSkewX(Infinity) threw exception TypeError: Failed to execute '
setSkewX' on 'SVGTransform': The provided float value is non-finite.. | |
122 | |
123 Check passing invalid arguments to 'setSkewY' | |
124 PASS transform.setSkewY() threw exception TypeError: Failed to execute 'setSkewY
' on 'SVGTransform': 1 argument required, but only 0 present.. | |
125 PASS transform.setSkewY(transform) threw exception TypeError: Failed to execute
'setSkewY' on 'SVGTransform': The provided float value is non-finite.. | |
126 PASS transform.setSkewY(svgElement) threw exception TypeError: Failed to execute
'setSkewY' on 'SVGTransform': The provided float value is non-finite.. | |
127 PASS transform.setSkewY('aString') threw exception TypeError: Failed to execute
'setSkewY' on 'SVGTransform': The provided float value is non-finite.. | |
128 PASS transform.setSkewY(NaN) threw exception TypeError: Failed to execute 'setSk
ewY' on 'SVGTransform': The provided float value is non-finite.. | |
129 PASS transform.setSkewY(Infinity) threw exception TypeError: Failed to execute '
setSkewY' on 'SVGTransform': The provided float value is non-finite.. | |
130 PASS successfullyParsed is true | |
131 | |
132 TEST COMPLETE | |
133 | |
OLD | NEW |