agentleFS
reddygopalkrishnareddygopalkrishna/developer-agent-skills/skills/verify-before-done/SKILL.md

verify-before-done

Skill8 starsChanged 9 days agoMITView on GitHub

Proves a code change works before calling it done by finding and running the project's build, typecheck, lint and tests, reading the output and fixing failures, plus a browser check for UI changes. Use when finishing any coding task, before saying a change is complete, fixed or working, before handing work back for review, or when the user asks to verify, check or test a change.

11 other projects use a version of this.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

12 rules. 0 are common, 11 are distinctive, and 1 is very specific to this project.

  • 0

    Common

    Most of the 10 edited versions we read keep these.

  • 11

    Distinctive

    This author's own choices. Worth a look.

  • 1

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    After fixing a bug, before saying it is fixed.

    line 14
  2. Distinctive:

    When the user asks "does it work?", "verify this", "run the checks".

    line 15
  3. Distinctive:

    Not for: designing a test suite (use the test-strategy skill) or writing new unit tests (use the unit-testing skill).

    line 17
  4. Distinctive:

    If none of these exist, use the ecosystem defaults in the table below.

    line 25
  5. Distinctive:

    Get a baseline when you can: Before changing code, run the checks once.

    line 26
  6. Distinctive:

    Use these only when the project defines nothing of its own.

    line 40
  7. Distinctive:

    Only run a tool the project already has installed or configured.

    line 52
  8. Distinctive:

    Stop the dev server: when you are done.

    line 67
  9. Distinctive:

    No proof, no claim: If you could not run a check (missing tool, no network, needs secrets), say exactly which check and why.

    line 71
  10. Very specific:

    Never make checks pass by weakening them: Don't skip or delete tests, loosen assertions, add @ts-ignore / # type: ignore / eslint-disable, …

    line 72
  11. Distinctive:

    Every check the project's CI runs has been run locally on the final code, or listed as not run with a reason.

    line 101
  12. Distinctive:

    All failures caused by the change are fixed.

    line 102

“Common” is measured: kept by at least 6 in 10 of the 10 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Verify Before Done

"Done" means you ran the project's own checks on the final code and saw them pass. Never say a change works, is fixed, or is complete based on reading the code. Report what you ran and what it printed.

When to use

  • At the end of every coding task, before telling the user it is finished.
  • After fixing a bug, before saying it is fixed.
  • When the user asks "does it work?", "verify this", "run the checks".

Not for: designing a test suite (use the test-strategy skill) or writing new unit tests (use the unit-testing skill). This skill runs what exists and checks the result.

Workflow

  1. Find the checks the project actually uses. CI config is the source of truth, because it is what gates merges. Look in this order:
    • CI files: .github/workflows/*.yml, .gitlab-ci.yml, azure-pipelines.yml, Jenkinsfile, .circleci/config.yml.
    • Task runners: package.json scripts, Makefile, justfile, Taskfile.yml, tox.ini, noxfile.py.
    • Project docs: README, CONTRIBUTING, any agent instructions file.
    • If none of these exist, use the ecosystem defaults in the table below.
  2. Get a baseline when you can. Before changing code, run the checks once. Failures that exist before your change are not yours, but you must report them. If you only start verifying at the end, say which failures you could not attribute.
  3. Run the checks on the final code, in this order, stopping to fix as you go:
    1. Install or restore dependencies if the lockfile changed.
    2. Build / compile.
    3. Typecheck.
    4. Lint and format check (use check mode, such as prettier --check or ruff format --check, not write mode, unless the project expects auto-fix).
    5. Tests: run the tests closest to your change first for fast feedback, then the full suite or the CI test command.
  4. Read the output, not just the exit code. Note the counts (passed, failed, skipped). Look for new warnings, deprecation notices you introduced, and tests that were skipped or did not run at all. "0 tests ran" is a failure, not a pass.
  5. Fix failures caused by your change, then rerun the failed step and everything after it. Repeat until clean. If a failure is pre-existing or unrelated, leave it alone and report it with the evidence.
  6. For UI or web changes, check in a browser (next section). Backend-only, library and CLI changes skip this step.
  7. Report using the template below.

Default commands by ecosystem

Use these only when the project defines nothing of its own.

EcosystemBuildTypecheckLintTest
JS/TS (npm, pnpm, yarn)npm run buildnpx tsc --noEmitnpm run lintnpm test
Pythonpython -m build (packages only)mypy . or pyrightruff check .pytest
Gogo build ./...(part of build)go vet ./...go test ./...
Rustcargo build(part of build)cargo clippy --all-targetscargo test
Java / Kotlin (Maven)mvn -q compile(part of build)project pluginsmvn test or mvn verify
Java / Kotlin (Gradle)./gradlew build(part of build)project plugins./gradlew test
C# / .NETdotnet build(part of build)dotnet format --verify-no-changesdotnet test

Only run a tool the project already has installed or configured. Don't add a new linter or type checker as part of verifying.

Browser check for UI changes

A green test suite does not prove a page renders. For any change to markup, styles, client code, routing or a frontend build config:

  1. Start the dev server the project uses (for example npm run dev), in the background, and wait until it reports it is ready.
  2. Use whatever browser tool you have: a built-in browser, or a browser automation MCP server such as Chrome DevTools MCP or Playwright MCP. Then check:
    • The changed page loads with no error overlay and no blank screen.
    • The console has no new errors (warnings are worth a note).
    • Network requests the page makes succeed: no new 4xx/5xx responses, no failed asset loads.
    • The key flow you changed works end to end: click the button, submit the form, see the result.
    • The layout holds at a narrow mobile width (about 375 px) and at desktop width.
    • Take a screenshot as evidence if the tool supports it.
  3. If you have no browser tool, run the project's existing end-to-end tests (Playwright, Cypress, Selenium) if it has them. If not, give the user a short manual checklist: the URL to open, what to click, what they should see. Mention that they can add a browser MCP server so this can be checked automatically next time.
  4. Stop the dev server when you are done.

Rules

  • No proof, no claim. If you could not run a check (missing tool, no network, needs secrets), say exactly which check and why. Never round "I couldn't run it" up to "it works".
  • Never make checks pass by weakening them. Don't skip or delete tests, loosen assertions, add @ts-ignore / # type: ignore / eslint-disable, raise timeouts blindly, or commit with --no-verify. If a check is truly wrong, explain why and ask the user.
  • Don't fix unrelated failures silently. Report them. Fixing them is a separate task the user can approve.
  • Verify the final state. Any edit after your last check run means the checks must run again.
  • Don't touch shared environments. Verification runs locally or in CI. Never deploy, migrate a shared database, or call production services to verify, unless the user explicitly asks.

Report template

Verification
- Build: `npm run build` — passed
- Typecheck: `npx tsc --noEmit` — passed
- Lint: `npm run lint` — passed (0 warnings)
- Tests: `npm test` — 214 passed, 0 failed, 2 skipped (skipped before my change)
- Browser: /settings loads, no console errors, save flow works, layout OK at 375 px
- Not verified: e2e suite (needs staging credentials)
- Pre-existing failures: `api/orders.test.ts` "refund rounding" fails on main too

Anti-patterns

  • "This should work." Reasoning about code is not verification. Run it.
  • Exit code only. A test command that found no tests, or a build that printed errors and exited 0, looks green.
  • Partial runs reported as full. Running one test file and saying "tests pass".
  • Fix, then don't rerun. The last edit broke something the earlier run would have caught.
  • Browser skipped for UI work because unit tests passed.
  • Green by deletion. Removing the failing test instead of fixing the code.

Done when

  • Every check the project's CI runs has been run locally on the final code, or listed as not run with a reason.
  • All failures caused by the change are fixed; pre-existing ones are reported with evidence.
  • UI changes were checked in a browser, by e2e tests, or with a manual checklist given to the user.
  • The user got a report listing each command and its result.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.