inkex.tester.svg module#

SVG specific utilities for tests.

inkex.tester.svg.svg(svg_attrs='')[source]#

Returns xml etree based on a simple SVG element.

svg_attrs: A string containing attributes to add to the

root <svg> element of a minimal SVG document.

inkex.tester.svg.svg_unit_scaled(width_unit)[source]#

Same as svg, but takes a width unit (top-level transform) for the new document.

The transform is the ratio between the SVG width and the viewBox width.

inkex.tester.svg.svg_file(filename)[source]#

Parse an svg file and return it’s document root