Free tools

JUnit XML Viewer: Read Test Results Online

Paste or drop the JUnit XML your test runner wrote to see failures grouped by message, the slowest tests and per-suite totals.

Runs in your browserNothing is uploadedNo sign-up

Paste the file, or choose or drop one or more files. Reads JUnit XML, TRX (Visual Studio / dotnet test), NUnit 3 XML, Playwright JSON, CTRF JSON.

Or drop files on the box. Nothing is uploaded.

How to get a JUnit XML file

Most runners write JUnit XML with one flag or one reporter. These are the commands from each tool's own documentation:

RunnerCommand or settingWhere the file goes
pytestpytest --junit-xml=report.xmlThe path you give
Playwrightnpx playwright test --reporter=junit with PLAYWRIGHT_JUNIT_OUTPUT_NAME=results.xml, or reporter: [['junit', { outputFile: 'results.xml' }]] in the configThe output file you set
Jestnpm install --save-dev jest-junit, then jest --ci --reporters=default --reporters=jest-junitjunit.xml in the working directory, unless JEST_JUNIT_OUTPUT_DIR or JEST_JUNIT_OUTPUT_NAME says otherwise
Gogotestsum --junitfile junit.xmlThe path you give
Maven SurefireRuns by default in mvn testOne TEST-<class>.xml per test class in target/surefire-reports

If your runner isn't listed, search its docs for "JUnit reporter": the format is the common exchange format for CI test results, and CircleCI, for one, requires it to split tests by timing.

What the viewer reads

A JUnit file is a <testsuites> element (optional) holding <testsuite> elements, each with <testcase> children. A test case with a <failure> child failed an assertion, one with <error> broke in another way (an exception, a setup crash), and one with <skipped> did not run. A test case with none of them passed.

  • Suite comes from the test case's classname, falling back to the suite's name.
  • Time is the time attribute in seconds. A missing time counts as 0.
  • Message is the message attribute of the failure, and the element's text is the stack trace or the failing code.
  • Retries: Maven Surefire, with -Dsurefire.rerunFailingTestsCount=2, records a test that failed and then passed with <flakyFailure> or <flakyError> elements, and every further failing rerun of a test that never passed with <rerunFailure> or <rerunError>. The viewer marks the first kind as flaky and counts both as retries.

When the file looks wrong

JUnit XML has no single official schema, so writers differ; the JUnit XML format guide shows what each runner writes. pytest, for example, can add a <properties> block to a test case with record_property, which its documentation warns breaks validation against the latest JUnit XML schema. Readers that only know one dialect then skip tests or reject the file. If a dashboard shows numbers that disagree with this viewer, run the file through the JUnit XML validator: it flags counts that don't match the test cases, times that aren't numbers and duplicate test names, with the line of each.

Sources

Testland for teams

In development

Automated test reports, manual test runs and regression tracking in one workspace. A separate product, built on the same skills.

One email when it opens, nothing else. Privacy policy