dart-migrate-to-checks-package

Migrate Dart test assertions from package:matcher expect patterns to package:checks syntax.

Updated May 2, 2026
One-click install
npx skills add https://github.com/Qunnnn/agents --skill dart-migrate-to-checks-package-qunnnn
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: dart-migrate-to-checks-package
Source: https://github.com/Qunnnn/agents/tree/main/skills/dart/dart-migrate-to-checks-package
Command: npx skills add https://github.com/Qunnnn/agents --skill dart-migrate-to-checks-package-qunnnn

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill helps Dart developers migrate legacy test assertions from package:matcher expect patterns to the more expressive package:checks API, reducing manual conversion effort and improving test readability.

Core Features & Use Cases

  • Assertion Migration: Converts common expect, matcher, and async assertion patterns into package:checks equivalents.
  • Dependency Guidance: Provides steps for adding package:checks, updating imports, and removing unnecessary matcher usage.
  • Use Case: Help a Dart project update its test suite from matcher-based assertions to modern checks-style assertions while preserving test behavior.

Quick Start

Ask the skill to migrate my Dart tests from package:matcher expect assertions to package:checks syntax.

Frequently Asked Questions about dart-migrate-to-checks-package

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I migrate Dart test assertions from package:matcher to package:checks?

To migrate Dart test assertions from package:matcher to package:checks, you convert legacy expect patterns to the more expressive checks syntax. This involves updating test imports, adding the checks dependency, and replacing matcher-based assertions while preserving original test behavior.

What is the difference between package:matcher and package:checks in Dart testing?

The difference between package:matcher and package:checks is that checks provides a more expressive API for Dart testing. Migrating to package:checks replaces traditional expect patterns with modern checks-style assertions, improving test readability and reducing manual conversion effort.

How do I update Flutter test imports when switching to the checks package?

To update Flutter test imports when switching to the checks package, you add the package:checks dependency and remove unnecessary package:matcher usage. This dependency change is a required step to validate and support the new checks-style assertion syntax.

Can I convert async Dart test assertions to checks syntax?

Yes, you can convert async Dart test assertions to checks syntax. The migration process specifically applies to Dart testing workflows involving async test migration scenarios, transforming async assertion patterns into their package:checks equivalents.

Does migrating to package:checks preserve existing Dart test behavior?

Migrating to package:checks does preserve existing Dart test behavior. The migration process includes validation steps for converting matcher-based tests, ensuring that updating to modern checks-style assertions maintains the original test outcomes.