test-cli-usability
Installation
SKILL.md
Test Your CLI's Agent Usability
This recipe helps you write scenario tests that verify your CLI tool works well when operated by AI agents (Claude Code, Cursor, Codex, etc.). A CLI that's agent-friendly means:
- All commands can run non-interactively (no stdin prompts that hang)
- Output is parseable and informative
- Error messages are clear enough for an agent to self-correct
- Help text enables discovery (
--helpworks on every subcommand)
Prerequisites
Install the Scenario SDK:
npm install @langwatch/scenario vitest @ai-sdk/openai
# or: pip install langwatch-scenario pytest