wpt / svg / geometry / parsing / cx-attribute-valid.svg

Status: FAIL | Duration: 55ms | Subtests: 0/6 | Open test on wpt.live | wpt.fyi

Data from commit:
a50cb89 wpt: run reference-named files which are themselves tests (#836) (2026-09-03)

SubtestStatusMessage
cx="0" should be a valid attribute valueFAILcannot convert 'null' or 'undefined' to object
cx="5" should be a valid attribute valueFAILcannot convert 'null' or 'undefined' to object
cx="-10" should be a valid attribute valueFAILcannot convert 'null' or 'undefined' to object
cx="5px" should be a valid attribute valueFAILcannot convert 'null' or 'undefined' to object
cx="-10px" should be a valid attribute valueFAILcannot convert 'null' or 'undefined' to object
cx="5%" should be a valid attribute valueFAILcannot convert 'null' or 'undefined' to object

/svg/geometry/parsing/cx-attribute-valid.svg

<?xml version="1.0" encoding="UTF-8"?>
<svg xmlns="http://www.w3.org/2000/svg"
     xmlns:h="http://www.w3.org/1999/xhtml"
     width="800px" height="800px">
  <title>SVG Geometry Properties: parsing the cx presentation attribute with valid values</title>
  <metadata>
    <h:link rel="help" href="https://w3c.github.io/svgwg/svg2-draft/geometry.html#CX"/>
    <h:link rel="help" href="https://w3c.github.io/svgwg/svg2-draft/types.html#presentation-attribute-css-value"/>
    <h:link rel="help" href="https://github.com/web-platform-tests/wpt/issues/61017"/>
    <h:meta name="assert" content="the cx presentation attribute supports '&lt;length-percentage&gt; | &lt;number&gt;' (unlike the cx CSS property, which does not accept a bare number)."/>
  </metadata>
  <circle id="target"/>
  <h:script src="/resources/testharness.js"/>
  <h:script src="/resources/testharnessreport.js"/>
  <h:script src="support/attribute-testcommon.js"/>
  <script><![CDATA[

test_valid_attribute_value("cx", "0", 0);
test_valid_attribute_value("cx", "5", 5);
test_valid_attribute_value("cx", "-10", -10);
test_valid_attribute_value("cx", "5px", 5);
test_valid_attribute_value("cx", "-10px", -10);
test_valid_attribute_value("cx", "5%", 40, "5%");

  ]]></script>
</svg>