Skip to content

Test Authoring

Susant Sahani edited this page Aug 18, 2026 · 2 revisions

Test Authoring

How requirements become Playwright tests. Deep: test-authoring.md · Tutorials 02 · 03 · 04.

Three ways to create tests

Mode How LLM?
Manual Write .spec.ts under tests/manual/ No
Spec-driven Markdown with ## Acceptance Criteria → generate Optional (richer TS)
Natural language argus test create "…" Required

Local spec → pipeline

# Example spec
argus test generate --spec prompts/examples/vm-create.md
cat tests/fixtures/requirements.json   # what the parser understood

argus test run --source local --spec path/to/feature.md

GitHub as source

# .env
ZYVOR_PRODUCT_REPO=owner/repo
# GITHUB_TOKEN or: gh auth login

argus test run --source github --spec docs/specs/my-feature.md
argus test run --source github                    # qa-labeled issues + docs/specs/ + README/CHANGELOG
argus test run --source github --pr-number 42     # + PR comment
argus test discover --source github
argus test run --source github --expand-coverage

Webhook automation: set GITHUB_WEBHOOK_SECRET, argus serve, point repo webhook at /webhook/github for push / pull_request / repository_dispatch.

Natural language

argus test create "Verify the homepage Schedule Demo button is visible" --execute
# Promote keepers from tests/generated/ → tests/manual/

Name the route and visible text in the sentence — they become goto + getByText.

Layout tips

  • Specs: user stories + acceptance criteria
  • Generated: tests/generated/ (ephemeral OK)
  • Hand-owned: tests/manual/
  • Artifacts: reports/, traces/, screenshots/

Related: CLI Commands · Architecture.

Clone this wiki locally