junitparser
Manipulates JUnit/xUnit Result XML files
Decision gist · record as of 2026-08-14
Yes. junitparser is a stable, actively maintained library with zero dependencies, permissive licensing, and no known vulnerabilities. Install it if you need to parse, generate, or manipulate JUnit/xUnit XML test reports. The Python 3.10+ requirement is the only constraint; if you're on an older Python version, use version 4.0.2 instead.AI-flagged interpretation of the facts on this page — verify before relying
Before you install
- Requires Python 3.10 or above; version 4.0.2 is needed for Python 3.9 or below.
- Low friction install with no runtime dependencies.
- Actively maintained as of July 2026 with recent releases.
License · maintenance · safety
Apache-2.0 (permissive) — Apache-2.0 permissive license allows commercial and private use with minimal restrictions.
last release 2026-06-05 (70 days) · last repo commit 2026-07-29 · 140 stars
0 known vulnerabilities (OSV.dev, 2026-08-14) · 14,143,836 downloads/mo, #1,245 on PyPI
Alternatives
Verify before relying
pip install junitparser
from junitparser import TestCase, TestSuite, JUnitXml
case = TestCase('test_name')
suite = TestSuite('suite_name')
suite.add_testcase(case)
xml = JUnitXml()
xml.add_testsuite(suite)
xml.write('results.xml')- Whether the package handles all real-world JUnit/xUnit XML variants beyond the windyroad schema and xunit2.
- Performance characteristics when parsing or merging very large XML files.
What it is and what it does
junitparser is a Python library for working with JUnit/xUnit test result XML files. It lets you parse existing XML reports, modify them programmatically, create new reports from scratch, and merge multiple result files together. The library supports the standard windyroad schema by default and can be extended with additional schemas like xunit2 through imports from submodules. It also provides a command-line interface for common operations like merging and verification.
The package has no external runtime dependencies, making it lightweight to install. It supports custom XML attributes and elements through monkey-patching, and allows you to specify alternative XML parsers like lxml for performance optimization. The library is actively maintained and requires Python 3.10 or above in its current version.
Use it for
- Merge multiple test result XML files from parallel test runs into a single consolidated report.
- Parse existing JUnit XML files to extract test metrics, failure counts, or other metadata for analysis.
- Generate JUnit XML reports programmatically from custom test frameworks or CI/CD pipelines.
- Modify test result XML files to add properties, change classnames, or update test outcomes.
- Support extended test result formats like xunit2 with additional attributes such as interim results or system error logging.
Worth the install?
AI-flagged interpretation of the facts on this page. Verify before relying on it.
Yes.
junitparser is a stable, actively maintained library with zero dependencies, permissive licensing, and no known vulnerabilities. Install it if you need to parse, generate, or manipulate JUnit/xUnit XML test reports. The Python 3.10+ requirement is the only constraint; if you're on an older Python version, use version 4.0.2 instead.
Install
junitparser on PyPI
Before you install
Low friction install with no runtime dependencies. Actively maintained as of July 2026 with recent releases.
Requires Python 3.10 or above; version 4.0.2 is needed for Python 3.9 or below.
License in practice
Apache-2.0 permissive license allows commercial and private use with minimal restrictions.
Quickstart
pip install junitparser
from junitparser import TestCase, TestSuite, JUnitXml
case = TestCase('test_name')
suite = TestSuite('suite_name')
suite.add_testcase(case)
xml = JUnitXml()
xml.add_testsuite(suite)
xml.write('results.xml')
Verify before relying
- Whether the package handles all real-world JUnit/xUnit XML variants beyond the windyroad schema and xunit2.
- Performance characteristics when parsing or merging very large XML files.
Package facts
| License | Apache-2.0 permissive |
| Python support | Supports the current Python release >=3.10 |
| Install friction | Low. Pure-Python wheel |
| Runtime dependencies | None |
| Maintenance | Actively maintained 70 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 14,143,836 / month, #1,245 on PyPI 30-day window, as of 2026-08-14 |
| Known vulnerabilities | None known OSV.dev, checked 2026-08-14 |
| Classifiers | Development Status :: 5 - Production/StableIntended Audience :: DevelopersProgramming Language :: Python :: 3Topic :: Text Processing |
Evidence: junitparser-5.0.1-py3-none-any.whl
Tags
Let your AI agent find packages like this
Example. Real query, live index.
You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.
wish › “junit xml parser”
- junitparserParse, create, and manipulate JUnit/xUnit test result XML files,…
- xunitparserParses JUnit/XUnit XML test result files and maps them to Python…
- flake8-formatter-junit-xmlFormats flake8 linting output as JUnit XML, enabling integration with…
Give your agent the search over MCP, or paste the wish link into any chat.
More Text Processing packages
A drop-in replacement for Python's standard `re` module that adds advanced regex features like nested sets, fuzzy matching, lookaround in conditionals, and full Unicode case-folding while maintaining backward compatibility.
pyparsing provides a library for building text parsers directly in Python code using composable grammar classes, handling quoted strings, whitespace variation, and embedded comments without regex or lex/yacc.
Install it if you need to parse text or define grammars programmatically.
fonttools manipulates font files in multiple formats (TrueType, OpenType, AFM, Type 1, Mac-specific) and includes TTX, a tool to convert fonts to and from XML text format.
Install it if you need to read, write, or manipulate fonts programmatically or via the TTX command-line tool.
Docutils converts plaintext documentation in reStructuredText format into multiple output formats including HTML, XML, and LaTeX using a modular processing system.
RapidFuzz provides fast fuzzy string matching using Levenshtein Distance and related metrics, implemented mostly in C++ with Python bindings for rapid similarity scoring and approximate string matching.
Install it if you need fuzzy string matching; it's a solid replacement for FuzzyWuzzy with better licensing and performance.
tinycss2 parses CSS strings into token and block objects, and generates CSS strings from those objects, following the CSS Syntax Level 3 specification without enforcing specific properties or values.
Install it if your project requires CSS tokenization or syntax manipulation.
See also junit2html · xunitparser · junit-xml · unittest-xml-reporting · xmlrunner · junit-xml-2 · secscanner2junit · flake8-formatter-junit-xml · pylint-junit · testresources