terminal-emulator

Simulate terminal interactions to test CLI and TUI applications.

23.2k|2.0k|Updated Jul 18, 2025
One-click install
npx skills add https://github.com/slopus/happy --skill terminal-emulator
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: terminal-emulator
Source: https://github.com/slopus/happy/tree/main/.agents/skills/terminal-emulator
Command: npx skills add https://github.com/slopus/happy --skill terminal-emulator

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires @microsoft/tui-test, and includes scripts (resource) components.

What problem does it solve?

This Skill enables you to simulate terminal interfaces, which is invaluable for testing command-line interfaces (CLI) and Text User Interface (TUI) applications.

Core Features & Use Cases

  • Simulate Terminal Interactions: Interact with terminal applications as if you were using a physical terminal.
  • Automated Testing: Automated scripts can simulate user interactions to test the reliability and user experience of TUIs.
  • Use Case: You're developing a complex TUI application that must work under different input scenarios, including invalid input handling and long-term user interaction.

Quick Start

Run the test-cli-app script to simulate a CLI application within the terminal emulator.

Frequently Asked Questions about terminal-emulator

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I automate testing for CLI and TUI applications?

Automate testing for CLI and TUI applications by running the `test-cli-app` script to simulate interactive terminal prompts and render TUI elements. This approach replicates end-user commands for reliable quality assurance.

What is terminal simulation and when do I need it?

Terminal simulation replicates a physical terminal environment to test command-line interfaces. You need it when validating complex TUI applications under various input scenarios, including invalid input handling and long-term interactive sessions.

How do I simulate interactive terminal prompts for automated scripts?

Simulate interactive terminal prompts by executing the provided scripts that interface with the terminal emulator. This allows your automated scripts to replicate user interactions and validate the reliability of TUI applications.

Do I need @microsoft/tui-test to handle terminal interactions?

Yes, you need the @microsoft/tui-test package to handle terminal interactions. It is a required dependency that empowers the terminal emulator to simulate interactive prompts and render TUI applications accurately.

Can I test invalid input handling in TUI applications using a terminal emulator?

Yes, you can test invalid input handling in TUI applications by scripting automated tests within the terminal emulator. It simulates complex user interactions to ensure your application handles unexpected inputs gracefully.

What's the best way to script automated tests for interactive CLI tools?

The best way to script automated tests for interactive CLI tools is using a terminal emulator to simulate end-user commands. This approach ensures your automated scripts accurately replicate physical terminal interactions for quality assurance.