JUnit viewer for VSCode
- TypeScript 72.4%
- CSS 20.9%
- JavaScript 3.2%
- Nix 1.8%
- Just 1.7%
| .vscode | ||
| assets | ||
| examples | ||
| l10n | ||
| resources | ||
| scripts | ||
| src | ||
| .envrc | ||
| .gitignore | ||
| .vscodeignore | ||
| .yarnrc.yml | ||
| AGENTS.md | ||
| devenv.lock | ||
| devenv.nix | ||
| devenv.yaml | ||
| justfile | ||
| LICENSE | ||
| package.json | ||
| package.nls.json | ||
| package.nls.zh-cn.json | ||
| README.md | ||
| tsconfig.extension.json | ||
| tsconfig.json | ||
| tsconfig.webview.json | ||
| yarn.lock | ||
⚠️ Warning
This extension is mostly AI-generated. Use with caution.
A rich JUnit XML test result viewer for VS Code. Open any JUnit-style .xml report and instantly browse its suites, test cases, failures, and stack traces through an interactive UI — right inside your editor.
Features
- Custom Editor — Open
.xmlfiles as formatted JUnit reports with the Open With → JUnit Report Viewer command - Rich Test Details — Class name, method name, execution time, status, failure message, and full stack traces
- Suite Grouping — Test cases are grouped by their parent
<testsuite> - Pass / Fail Filter — One-click toggle to show or hide passing tests
- File Watching — Automatically refreshes the report when the underlying XML file changes
Installation
From VSIX
# Build and package
just package
# Install in VS Code
code --install-extension dist/junit-viewer-*.vsix
Development
Press F5 to launch the Extension Development Host and try the extension in a sandboxed VS Code window.
Usage
Opening a JUnit XML Report
- Explorer context menu — Right-click a
.xmlfile → View as JUnit Report - Editor title button — Click the
icon while viewing any XML file - Command Palette —
Ctrl+Shift+P→ Open JUnit XML File… - Custom editor — Open With → JUnit Report Viewer on any
.xmlfile - Auto-detect — Opening a JUnit-formatted XML file loads it automatically
Supported JUnit XML Formats
<!-- Format 1: <testsuites> wrapping multiple <testsuite> elements -->
<testsuites>
<testsuite errors="0" failures="1" name="MySuite" tests="3" time="1.234">
<testcase classname="com.example.Test" name="testFoo" time="0.123"/>
<testcase classname="com.example.Test" name="testBar" time="0.456">
<failure message="expected 1 but got 2" type="AssertionError">
at com.example.Test.testBar(Test.java:42)
</failure>
</testcase>
</testsuite>
</testsuites>
<!-- Format 2: standalone <testsuite> root element -->
<testsuite errors="0" failures="0" name="MySuite" tests="1" time="0.123">
<testcase classname="com.example.Test" name="testFoo" time="0.123"/>
</testsuite>
Tech Stack
- TypeScript — Both the extension host and the webview
- SolidJS — Reactive UI framework for the webview
- esbuild — Fast bundler with SolidJS JSX plugin
- fast-xml-parser — XML parsing with attribute-aware mode
Development
Prerequisites
Quick Start
# Enter the development environment
devenv shell
# Install dependencies
yarn install
# Development build with watch mode
just watch
# Type-check only
just check
# Production build
just build
# Package as .vsix
just package
