better_test_reporter
0.1.1, released 5 years ago by betterment.dev
CLI to convert Dart test JSON output to JUnit XML and provide models
What it does
It parses the JSON output from Dart's test reporter into developer-friendly models and can generate a JUnit XML report for CI tools. The package also offers a command-line tool to perform this conversion directly from the terminal.
AI-written summary of version 0.1.1, based on the package's README and metadata. Report an inaccuracy
Use it when
- Generating CI-friendly JUnit reports from Dart test runs
- Parsing test JSON into reusable Dart models for custom reporting
- Automating test report generation in CI pipelines
Skip it when
- When you need a fully-featured, production-ready test reporting solution
- When you only need basic test output without XML conversion
Strengths
- Single package for parsing and CLI conversion
- Null-safety and modern Dart support
- Easy global installation via pub global activate
Weaknesses
- Experimental status, limited feature set
- No extensive documentation beyond README
- No built-in support for non-CI use cases
Setup
- Kind
- Pure Dart
- Effort
- Low
- Code generation
- Yes (build_runner)
- Direct dependencies
- 6
pub global activate better_test_reporter
```bash
pub global activate better_test_reporter
report_to_junit --input test_report.json --output report.xml
```Alternatives
Packages that do the same job and could replace better_test_reporter.
- deep_pick
Type-safe API for manual JSON parsing with useful error messages.
91Compare - json_schema
Validate JSON data against JSON Schema drafts in Dart.
63Compare - rsa_id_number
Validates, parses, and generates South African ID numbers.
55Compare - bosun
Library for parsing CLI input and structuring commands
40Compare
Works with
Packages commonly used together with better_test_reporter: ones it builds on, ones built on it, and its own family.
- pub_semverbetter_test_reporter depends on itVersions and version constraints implementing pub's versioning policy.
- xmlbetter_test_reporter depends on itFull-featured XML and XPath library for DOM parsing, SAX streaming, and fluent building.
- json_annotationbetter_test_reporter depends on itProvides annotations for json_serializable to generate JSON (de)serialization code.
- argsbetter_test_reporter depends on itLibrary for parsing raw command-line arguments into options and values using GNU and POSIX styles.
- intlbetter_test_reporter depends on itA Dart library for internationalization and localization, providing message translation, plural/gender handling, and date/number formatting.
- freezed_annotationbetter_test_reporter depends on itAnnotations for the freezed code-generator.