swift-test-authoring

Test Swift and SwiftUI state, networking, and view behavior.

SKILL.md

GitHub

Swift test authoring

Read applicable AGENTS.md and their declared adapter alias, otherwise .agents/skills/swift-test-authoring/SKILL.md from the repository root if present. Local policy overrides these defaults; do not reload an already-read adapter or canonical skill.

Apply test-authoring.

  • Test public behavior with deterministic inputs and injected dependencies.
  • For SwiftUI, inspect or interact through the project's supported test approach.
  • For networking, use a protocol-level test double. Keep request and response synchronization explicit.
  • Avoid sleeps and global state. Keep fixtures small enough that a failure is readable.
  • Read network test doubles for cancellation and shared-state safety.

Consumer wrapper owns: test targets, coverage thresholds, view-inspection libraries, and fixture APIs.