scenario 0.1.0

Define and test CLI behavior scenarios — input/output, interactive sessions, and terminal conditions (TTY, dimensions, color)
Documentation

scenario

Define and test CLI behavior scenarios under controlled terminal conditions.

scenario provides infrastructure for testing CLI applications across different terminal environments — with or without a TTY, at various terminal widths, with or without color support.

Features

  • Snapshot testing of CLI stdout, stderr, and exit codes via insta
  • PTY simulation via portable-pty — your binary sees a real terminal
  • Terminal dimension control — test narrow (40 cols), standard (80), wide (200)
  • Color/no-color testing — verify both human and machine output
  • Interactive session testing — send input, expect output patterns