test-best-practices

Installation
SKILL.md

When to use this skill

In a Dart or Flutter project. When a user asks to "enforce test best practices" or similar. When modifying or creating test files.

Workflow

  1. Search: Use the grep commands below to identify candidates.
  2. Analyze: Check if the code violates the best practices defined below.
  3. Apply: Refactor the code to use the recommended matchers.
  4. Verify: Run tests (dart test) to ensure no regressions.

Search Strategies

  • .length: grep -r "\.length,\s*equals\(" test/
  • Boolean properties: grep -rE "expect\(.*\.(is(Empty|NotEmpty)),\s*(isTrue|true|isFalse|false)" test/
  • Manual loops: grep -r "for (var .* in .*)" test/ (manual review required)
Related skills
Installs
4
GitHub Stars
136
First Seen
Feb 6, 2026