skills/smithery.ai/writing-unit-tests

writing-unit-tests

SKILL.md

Writing Unit Tests Skill

This skill provides guidelines for AI agents writing unit tests for the Hex1b TUI library. It outlines the preferred testing approach, patterns, and anti-patterns to avoid.

Core Philosophy

  1. Prefer full terminal stack testing - Use Hex1bTerminal.CreateBuilder() to create complete terminal environments
  2. Use .WithHex1bApp() for TUI functionality tests - This wires up the full app lifecycle
  3. Keep tests simple and linear - Avoid excessive abstractions; repeating patterns are beneficial for AI agents
  4. Assert on visual behavior - Use CellPatternSearcher and color assertions for render verification
  5. Update this skill when discovering new patterns - Build the body of knowledge as part of PRs

When to Use Full Stack vs Isolation

Installs
2
First Seen
Mar 28, 2026