Files
gh-johnclyde-clydehub/commands/test-debug.md
2025-11-30 08:28:27 +08:00

868 B

description, argument-hint
description argument-hint
Run and debug a specific failing test
test-name-or-path

Debug a specific failing test:

  1. Identify the test command for the project (pnpm test, uv run pytest)
  2. Run the specific test provided in the argument
  3. If test fails, analyze the error output
  4. Suggest potential fixes based on the failure
  5. Allow iterative debugging with repeated test runs
  6. After test passes, run linters and fix issues (pnpm biome check --write, uv run ruff check --fix, uv run ruff format)
  7. Run type checking (pnpm tsc --noEmit for TypeScript, uv run ty check for Python)
  8. Run the test again to ensure it still passes after lint/type fixes
  9. Stage all changes if everything passes

IMPORTANT: This is for investigating specific test failures, not for running the full test suite. All linting and type checking must pass before completing.