Search packages, repositories and app categories

Package detailsv3.5.23

build_test

Utilities for writing unit tests of Builders.

macOSWindowsLinux
30-day downloads
242K
Likes
11
Pub points
140

Install package

flutter pub add build_test

Package Overview

Package selection guidance compiled from public package information, community data, and project usage.

A Dart package providing utilities for writing unit tests for build runners and transformers. It enables developers to test the behavior of code generation and transformation logic in isolation, ensuring correctness and reliability of build processes. The package integrates with the broader build system ecosystem, offering helpers for setting up test environments, simulating inputs, and validating outputs. Designed for use in automated testing workflows, it supports both simple and complex build scenarios.

Use cases

  • Testing custom builders
  • Validating code generation logic
  • Simulating build environments
  • Debugging transformer behavior
  • Ensuring build consistency

Key features

  • Test-specific builder utilities
  • Input/output simulation
  • Integration with build system
  • Support for isolated testing
  • Mocking build contexts

Suitable for

  • Dart package maintainers
  • Build system developers
  • Code generation tool creators
  • Testing build logic

Considerations

  • Requires knowledge of the build system
  • Not suitable for runtime testing
  • Depends on build_runner
  • Limited to build-related testing
  • Needs proper setup for mocks

Original README

Original README snapshot from the linked source repository. Visit the repository for the latest content.

Questions? Suggestions? Found a bug? Please file an issue or start a discussion.

Code generation for Flutter and Dart packages.

See the build_runner package documentation for how to use build_runner builders in your package to add serialization, data classes, data binding, dependency injection, mocking and more.

See the build package documentation to create your own builder.

This repo also hosts the following builders and packages for use by builders.

Categories

Dependencies

Dependency list 15 items

Source repository

Projects using this package