blob: d255097a01c2c3ec54a47698408fc7711f854513 [file] [log] [blame]
This test checks the SVGAnimatedEnumeration API - utilizing the clipPathUnits property of SVGClipPathElement
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
Check initial clipPathUnits value
PASS clipPathElement.clipPathUnits.toString() is "[object SVGAnimatedEnumeration]"
PASS typeof(clipPathElement.clipPathUnits.baseVal) is "number"
PASS clipPathElement.clipPathUnits.baseVal is SVGUnitTypes.SVG_UNIT_TYPE_USERSPACEONUSE
Check that enumerations are static, caching value in a local variable and modifying it, should have no effect
PASS enumRef is SVGUnitTypes.SVG_UNIT_TYPE_OBJECTBOUNDINGBOX
PASS clipPathElement.clipPathUnits.baseVal is SVGUnitTypes.SVG_UNIT_TYPE_USERSPACEONUSE
Check assigning various valid and invalid values
PASS clipPathElement.clipPathUnits.baseVal = 3 threw exception TypeError: Type error.
PASS clipPathElement.clipPathUnits.baseVal is SVGUnitTypes.SVG_UNIT_TYPE_USERSPACEONUSE
PASS clipPathElement.clipPathUnits.baseVal = -1 threw exception TypeError: Type error.
PASS clipPathElement.clipPathUnits.baseVal is SVGUnitTypes.SVG_UNIT_TYPE_USERSPACEONUSE
PASS clipPathElement.clipPathUnits.baseVal = '1' is "1"
PASS clipPathElement.clipPathUnits.baseVal is SVGUnitTypes.SVG_UNIT_TYPE_USERSPACEONUSE
PASS clipPathElement.clipPathUnits.baseVal = 'aString' threw exception TypeError: Type error.
PASS clipPathElement.clipPathUnits.baseVal is SVGUnitTypes.SVG_UNIT_TYPE_USERSPACEONUSE
PASS clipPathElement.clipPathUnits.baseVal = 2 is SVGUnitTypes.SVG_UNIT_TYPE_OBJECTBOUNDINGBOX
PASS clipPathElement.clipPathUnits.baseVal = clipPathElement threw exception TypeError: Type error.
PASS clipPathElement.clipPathUnits.baseVal is SVGUnitTypes.SVG_UNIT_TYPE_OBJECTBOUNDINGBOX
PASS successfullyParsed is true
TEST COMPLETE