dart-test-fundamentals

dart-test-fundamentals is a skill for Claude Code, Codex from mdazadhossain95/flutter-agent-skills. It costs 43 tokens per session (970 once invoked), scanned A, a copy of dart-test-fundamentals, MIT.

A guide to writing tests in Dart with package:test, Dart's standard testing package. It explains individual tests, test groups, setup and cleanup steps, and the dart_test.yaml configuration file.

In plain words
What is it for?
Creating Dart tests, grouping related cases, naming tests clearly, using setUp and tearDown, and configuring test runs.
Why use it?
It helps organize test files and avoid confusion about how tests run before and after each case or group. It also explains how to configure test execution.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one. Also seen: installed under .agents/ (shared by several agents).

Good fit Creating Dart tests, grouping related cases, naming tests clearly, using setUp and tearDown, and configuring test runs.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/mdazadhossain95/flutter-agent-skills/dart-test-fundamentals
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add mdazadhossain95/flutter-agent-skills --skill dart-test-fundamentals
Clone the repo
git clone --depth 1 https://github.com/mdazadhossain95/flutter-agent-skills

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for dart-test-fundamentals

README.md
[![agentmods](https://agentmods.dev/badge/skills/mdazadhossain95/flutter-agent-skills/dart-test-fundamentals/github.svg)](https://agentmods.dev/skills/mdazadhossain95/flutter-agent-skills/dart-test-fundamentals)
Your own site
<a href="https://agentmods.dev/skills/mdazadhossain95/flutter-agent-skills/dart-test-fundamentals"><img src="https://agentmods.dev/badge/skills/mdazadhossain95/flutter-agent-skills/dart-test-fundamentals/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for dart-test-fundamentals

Your own site · 80×15
<a href="https://agentmods.dev/skills/mdazadhossain95/flutter-agent-skills/dart-test-fundamentals"><img src="https://agentmods.dev/badge/skills/mdazadhossain95/flutter-agent-skills/dart-test-fundamentals.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 43 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 970 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin 89% copy Near-identical to another mod in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00043 $0.00970
Opus 5 $0.00022 $0.00485
Sonnet 5 $0.00009 $0.00194
Haiku 4.5 $0.00004 $0.00097

Measured 11d ago against content hash 47db6e6f1fb8, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-11, from the pricing page.

Security

Grade A, and why

dart-test-fundamentals scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 11d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

Origin

This is a copy

89% identical to dart-test-fundamentals — 67 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.

tool/dart_skills_lint/.agents/skills/dart-test-fundamentals/SKILL.md · 128 lines

How it starts

The opening of the file, as written. The whole thing — 128 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Dart Test Fundamentals

When to use this skill

Use this skill when:

  • Writing new test files.
  • structuring test suites with group.
  • Configuring test execution via dart_test.yaml.
  • Understanding test lifecycle methods.

Core Concepts

1. Test Structure (test and group)

  • test: The fundamental unit of testing.

    test('description', () {
      // assertions
    });
    
  • group: Used to organize tests into logical blocks.

    • Groups can be nested.
    • Descriptions are concatenated (e.g., "Group Description Test Description").
    • Helps scope setUp and tearDown calls.
    • Naming: Use PascalCase for groups that correspond to a class name (e.g., group('MyClient', ...)).
    • Avoid Single Groups: Do not wrap all tests in a file with a single group call if it's the only one.
  • Naming Tests:

    • Avoid redundant "test" prefixes.
    • Include the expected behavior or outcome in the description (e.g., 'throws StateError' or 'adds API key to URL').
    • Descriptions should read well when concatenated with their group name.
  • Named Parameters Placement:

    • For test and group calls, place named parameters (e.g., testOn, timeout, skip) immediately after the description string, before the callback closure. This improves readability by keeping the test logic last.
      test('description', testOn: 'vm', () {
        // assertions
      });
      

2. Lifecycle Methods (setUp, tearDown)

  • setUp: Runs before every test in the current group (and nested groups).
  • tearDown: Runs after every test in the current group.
  • setUpAll: Runs once before any test in the group.
  • tearDownAll: Runs once after all tests in the group.

Best Practice:

  • Use setUp for resetting state to ensure test isolation.
  • Avoid sharing mutable state between tests without resetting it.

3. Configuration (dart_test.yaml)

The dart_test.yaml file configures the test runner. Common configurations include:

Read the full file on GitHub · 128 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 11d ago First seen · 128 lines · 43 tokens per session scan A 47db6e6f1fb8

Subscribe to this mod's changes

dart-test-fundamentals is a skill published in the GitHub repository mdazadhossain95/flutter-agent-skills (2 stars, last pushed 2mo ago), licensed MIT. It adds 43 tokens to every session and 970 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. It is 89% identical to dart-test-fundamentals, differing in 67 lines, and is treated as a copy.