xray-code-snippets
xray-code-snippets copied to clipboard
XSLT for XML-to-CSV transformations (like TestRail-to-Xray)
trafficstars
Is there any appeal to adding XSLT sample code for XML to CSV (for import to XRay) transformations, as an alternative to the Python scripts ?
I converted the TestRail-to-Xray script (cloud version), as an exercise at first, then out of stubbornness :).
The XSLT version came out a little wordier than the Python version, with about 25% more LOC, and XSLT might not be as widely familiar as Python (personally, I feel XSLT is under-appreciated).
Advantages I see, to XSLT over the existing Python samples:
- Native support for XML entity references
- Implicitly recursive
- Fewer dependencies to manage (e.g. the xslt3 npm package is enough)
Thanks for considering this, and thanks for the samples !