Source code
Revision control
Copy as Markdown
Other Tools
Test Info:
- This WPT test may be referenced by the following Test IDs:
- /svg/geometry/parsing/ellipse-ry-attribute-invalid.svg - WPT Dashboard Interop Dashboard
<?xml version="1.0" encoding="UTF-8"?>
width="800px" height="800px">
<title>SVG Geometry Properties: parsing the ry presentation attribute on ellipse with invalid values</title>
<metadata>
<h:link rel="help" href="https://w3c.github.io/svgwg/svg2-draft/types.html#presentation-attribute-css-value"/>
<h:meta name="assert" content="the ry presentation attribute on ellipse rejects negative values and values outside '<length-percentage> | <number> | auto', keeping the initial computed value of auto. A negative value for ry is invalid and must be ignored per SVG2 geometry.html#RY."/>
</metadata>
<ellipse id="target"/>
<h:script src="/resources/testharness.js"/>
<h:script src="/resources/testharnessreport.js"/>
<h:script src="support/attribute-testcommon.js"/>
<script><![CDATA[
test_invalid_attribute_value("ry", "-10", 0, "auto");
test_invalid_attribute_value("ry", "-10px", 0, "auto");
test_invalid_attribute_value("ry", "-10%", 0, "auto");
test_invalid_attribute_value("ry", "none", 0, "auto");
test_invalid_attribute_value("ry", "10px 20px", 0, "auto");
test_invalid_attribute_value("ry", "garbage", 0, "auto");
]]></script>
</svg>