analyzer_testing
0.4.5, released 3 weeks ago by tools.dart.dev
Testing utilities and mocks for Dart analyzer and analysis server plugins.
What it does
Provides testing helpers, mock package configurations, and resolution fixtures for developing analyzer tools and analysis server plugins. It assists in setting up test packages and configuring experimental features for Dart code analysis tests.
AI-written summary of version 0.4.5, based on the package's README and metadata. Report an inaccuracy
Use it when
- Writing automated tests for custom Dart analyzer plugins or lint rules
- Testing analysis server extensions that need mock packages or resolution environments
Skip it when
- Writing general Flutter unit, widget, or integration tests
- Not developing plugins or tools directly integrated with the Dart analyzer
Strengths
- Maintained directly as part of the Dart SDK ecosystem
- Simplifies mocking package configurations and mock dependencies like Flutter stubs in analyzer tests
Weaknesses
- Very tightly coupled to specific versions of the analyzer package (frequently requiring exact minor/patch versions)
- Sparse documentation with no usage examples provided in the README
Setup
- Kind
- Pure Dart
- Effort
- Low
- Code generation
- No
- Direct dependencies
- 6
Requires aligning analyzer dependency versions strictly to match the package requirements.
Alternatives
Packages that do the same job and could replace analyzer_testing.
- very_good_analysis
Lint rules for Dart and Flutter used internally at Very Good Ventures.
91Compare - leancode_lint
An opinionated set of high-quality, robust, and up-to-date lint rules used at LeanCode.
83Compare - golden_test
A zero-dependency wrapper for Flutter golden tests with theme, locale, and multi-device support.
79Compare - build_test
Utilities for unit testing Dart build_runner builders in memory
78Compare
Works with
Packages commonly used together with analyzer_testing: ones it builds on, ones built on it, and its own family.
- analyzeranalyzer_testing depends on itPerforms static analysis of Dart code for tool integration and embedding.
- testanalyzer_testing depends on itA full featured library for writing and running Dart tests across platforms.
- analyzer_pluginanalyzer_testing depends on itFramework for building plugins for the Dart analysis server
- analysis_server_pluginanalyzer_testing depends on itFramework and support code for building plugins for the Dart analysis server.
- dart_styleSame familyProvides an API and CLI to format Dart source code automatically.
- build_runnerSame familyA build system for Dart code generation and modular compilation.
- source_genSame familySource code generation builders and utilities for the Dart build system.
- panaSame familyProduce a report summarizing the health and quality of a Dart package