Test

From phj128/autoworker · View interactive version

Test is an AI agent skill from the GitHub repository phj128/autoworker. Execute ONE test level (L1/L2/L3/L4) from subtask verification plan. Only run tests, do not record results. Called by autoworker:dispatch with level argument. Ends by calling autoworker:checkpoint.

How to use this skill

Skill file

autoworker:test — Execute One Test Layer

Called by autoworker:dispatch with a target level argument. Does one thing: execute all test items for that layer from the subtask verification plan.

Execution Flow

1. Determine Target Level

2. Read Verification Plan

Glob `subtask_*.md` (exclude subtask_template.md) →
  0 found → stop, prompt to create subtask
  1 found → use directly (backward compatible)
  multiple → grep `status:` to filter:
    - Files without status field treated as active (backward compatible)
    - Exactly 1 active → use it
    - 0 active → list all files + status, prompt user to choose
    - >1 active → report anomaly
→ Read → extract all verification items for the target level

Each item contains:

3. Execute Verification Items One by One

For each verification item in the layer:

  1. Execute the verification command (long-running commands like training use run_in_background=true, then TaskOutput to wait for results)
  2. Record actual output
  3. Compare against expected, determine pass/fail
  4. Do not ask the user to manually execute any command — complete all verification autonomously

Pass determination hard standard:

4. Handle Failures

When a test fails:

  1. Analyze error cause, autonomously fix the bug → re-run all tests for the current layer
  2. Same approach fails consecutively twice → enter diagnostic mode
  3. After fixing code, record the fix in autoworker:checkpoint (don't just record test results — also record what code was changed)

5. Output Summary

When all pass:

L<N> tests passed:
- <item 1>: <actual output summary> PASS
- <item 2>: <actual output summary> PASS
→ Invoking autoworker:checkpoint

6. Chain: Immediately Invoke autoworker:checkpoint

After outputting the summary, immediately invoke autoworker:checkpoint. Do not wait for user instructions, do nothing else.

Key Constraints

Important Notes

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.