OLD | NEW |
| (Empty) |
1 This test checks the use of SVGAnimatedEnumeration within SVGFEBlendElement | |
2 | |
3 On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE
". | |
4 | |
5 | |
6 | |
7 Check initial 'mode' value | |
8 PASS feBlendElement.mode.toString() is "[object SVGAnimatedEnumeration]" | |
9 PASS typeof(feBlendElement.mode.baseVal) is "number" | |
10 PASS feBlendElement.mode.baseVal is SVGFEBlendElement.SVG_FEBLEND_MODE_NORMAL | |
11 | |
12 Switch to 'multiply' | |
13 PASS feBlendElement.mode.baseVal = SVGFEBlendElement.SVG_FEBLEND_MODE_MULTIPLY i
s SVGFEBlendElement.SVG_FEBLEND_MODE_MULTIPLY | |
14 PASS feBlendElement.mode.baseVal is SVGFEBlendElement.SVG_FEBLEND_MODE_MULTIPLY | |
15 PASS feBlendElement.getAttribute('mode') is "multiply" | |
16 | |
17 Switch to 'screen' | |
18 PASS feBlendElement.mode.baseVal = SVGFEBlendElement.SVG_FEBLEND_MODE_SCREEN is
SVGFEBlendElement.SVG_FEBLEND_MODE_SCREEN | |
19 PASS feBlendElement.mode.baseVal is SVGFEBlendElement.SVG_FEBLEND_MODE_SCREEN | |
20 PASS feBlendElement.getAttribute('mode') is "screen" | |
21 | |
22 Switch to 'darken' | |
23 PASS feBlendElement.mode.baseVal = SVGFEBlendElement.SVG_FEBLEND_MODE_DARKEN is
SVGFEBlendElement.SVG_FEBLEND_MODE_DARKEN | |
24 PASS feBlendElement.mode.baseVal is SVGFEBlendElement.SVG_FEBLEND_MODE_DARKEN | |
25 PASS feBlendElement.getAttribute('mode') is "darken" | |
26 | |
27 Switch to 'lighten' | |
28 PASS feBlendElement.mode.baseVal = SVGFEBlendElement.SVG_FEBLEND_MODE_LIGHTEN is
SVGFEBlendElement.SVG_FEBLEND_MODE_LIGHTEN | |
29 PASS feBlendElement.mode.baseVal is SVGFEBlendElement.SVG_FEBLEND_MODE_LIGHTEN | |
30 PASS feBlendElement.getAttribute('mode') is "lighten" | |
31 | |
32 Try setting invalid values | |
33 PASS feBlendElement.mode.baseVal = 6 threw exception TypeError: Failed to set th
e 'baseVal' property on 'SVGAnimatedEnumeration': The enumeration value provided
(6) is larger than the largest allowed value (5).. | |
34 PASS feBlendElement.mode.baseVal is SVGFEBlendElement.SVG_FEBLEND_MODE_LIGHTEN | |
35 PASS feBlendElement.getAttribute('mode') is "lighten" | |
36 PASS feBlendElement.mode.baseVal = -1 threw exception TypeError: Failed to set t
he 'baseVal' property on 'SVGAnimatedEnumeration': The enumeration value provide
d (65535) is larger than the largest allowed value (5).. | |
37 PASS feBlendElement.mode.baseVal is SVGFEBlendElement.SVG_FEBLEND_MODE_LIGHTEN | |
38 PASS feBlendElement.getAttribute('mode') is "lighten" | |
39 PASS feBlendElement.mode.baseVal = 0 threw exception TypeError: Failed to set th
e 'baseVal' property on 'SVGAnimatedEnumeration': The enumeration value provided
is 0, which is not settable.. | |
40 PASS feBlendElement.mode.baseVal is SVGFEBlendElement.SVG_FEBLEND_MODE_LIGHTEN | |
41 PASS feBlendElement.getAttribute('mode') is "lighten" | |
42 | |
43 Switch to 'normal' | |
44 PASS feBlendElement.mode.baseVal = SVGFEBlendElement.SVG_FEBLEND_MODE_NORMAL is
SVGFEBlendElement.SVG_FEBLEND_MODE_NORMAL | |
45 PASS feBlendElement.mode.baseVal is SVGFEBlendElement.SVG_FEBLEND_MODE_NORMAL | |
46 PASS feBlendElement.getAttribute('mode') is "normal" | |
47 | |
48 baseVal access when mode is set to a value not in SVGFEBlendElement.SVG_FEBLEND_
MODE_*. | |
49 PASS feBlendElement.mode.baseVal is SVGFEBlendElement.SVG_FEBLEND_MODE_UNKNOWN | |
50 PASS feBlendElement.mode.baseVal = 13 threw exception TypeError: Failed to set t
he 'baseVal' property on 'SVGAnimatedEnumeration': The enumeration value provide
d (13) is larger than the largest allowed value (5).. | |
51 PASS feBlendElement.getAttribute('mode') is "color-dodge" | |
52 PASS successfullyParsed is true | |
53 | |
54 TEST COMPLETE | |
55 | |
OLD | NEW |