testing

wham's avatarfrom wham

Guide for testing and verifying code changes in this TUI application. Use this skill after making ANY code changes to main.go or main.md to verify they work correctly.

⭐67stars🔀16forks📁View on GitHub🕐Updated Jan 1, 2026

When & Why to Use This Skill

This Claude skill streamlines the testing and verification process for Terminal User Interface (TUI) applications. It enables developers to automatically validate code changes, ensure UI consistency, and perform functional assertions within a terminal environment, significantly reducing manual QA effort and preventing regressions in Go-based projects.

Use Cases

  • Regression Testing: Automatically verify that updates to core logic (main.go) or documentation (main.md) do not break existing terminal interface functionality.
  • UI/UX Validation: Capture and analyze terminal screen buffers to ensure that menus, layouts, and display elements render correctly after UI modifications.
  • Automated User Simulation: Simulate complex keyboard inputs and control sequences to test application behavior and state transitions without manual intervention.
  • Early Error Detection: Utilize integrated 'go vet' and automated test flags to identify potential issues and syntax errors before the application is built or deployed.
nametesting
descriptionGuide for testing and verifying code changes in this TUI application. Use this skill after making ANY code changes to main.go or main.md to verify they work correctly.

Testing

This skill helps you create and run tests for terminal user interface (TUI) applications.

When to use this skill

Use this skill:

  • After making ANY code changes to verify they work correctly
  • When modifying UI elements, menus, or display logic
  • When changing application behavior or adding features
  • To ensure existing functionality as specified in main.md and README.md is not broken

Starting the application

  • Run scripts/run --test where the user would normally run github-brain
    • scripts/run --test pull equivalently runs github-brain pull
    • scripts/run --test mcp equivalently runs github-brain mcp
    • The --test flag runs go vet before building to catch issues early
  • Ensure .env files is configured to use the github-brain-test organization
  • Use GitHub MCP to add new issue/PRs/discussions as needed for testing
  • Simulate user input: Send key presses, control combinations, or specific commands to the running application.
  • Capture and analyze screen output: The testing tool captures the terminal display (or buffer) at specific moments in time.
  • Make assertions: Verify that the screen content matches the expected output (e.g., checking if specific text is present at certain coordinates or if the cursor position is correct).