본문으로 건너뛰기
cccskills
무료GitHub에 공개

terminal-emulator

Create and run tests for interactive command-line tools and terminal interfaces using @microsoft/tui-test. Simulate keyboard input, check visible text, and compare screen snapshots in a separate terminal environment for each test.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

원문원문 설명 보기

Test interactive CLI/TUI applications using @microsoft/tui-test. Use when you need to test CLI tools with interactive prompts, TUI rendering, arrow key navigation, or any command that requires a TTY. Triggers include "test CLI", "test TUI", "run interactively", "automate terminal input", "simulate user input in terminal".

설치 방법 보기

이럴 때 유용합니다

  • Testing selection prompts with arrow keys and Enter
  • Checking terminal screen snapshots
  • Automating text entry and keyboard navigation
  • Testing commands that require a terminal connection

포함된 파일(1)

  • SKILL.md2.4 KB

SKILL.md(원문)

설치하기 전에 에이전트에게 전달되는 지시 내용을 확인할 수 있습니다.

Testing Interactive CLI / TUI with @microsoft/tui-test

Playwright-like API for terminals. Real PTY per test. Made by Microsoft.

Install

yarn add -D @microsoft/tui-test

Usage

import { test, expect } from '@microsoft/tui-test';

test.use({ program: { file: 'node', args: ['./my-cli.js'] } });

test('selects option and proceeds', async ({ terminal }) => {
    await expect(terminal.getByText('Select an option')).toBeVisible();
    await terminal.write('\x1B[B');  // Arrow Down
    await terminal.submit();          // Enter
    await expect(terminal.getByText('Option 2 selected')).toBeVisible();
});

test('matches snapshot', async ({ terminal }) => {
    await expect(terminal).toMatchSnapshot();
});

API

// Navigation
await terminal.write('\x1B[A');    // Arrow Up
await terminal.write('\x1B[B');    // Arrow Down
await terminal.write('\x1B[C');    // Arrow Right
await terminal.write('\x1B[D');    // Arrow Left
await terminal.submit();           // Enter
await terminal.write('\t');        // Tab
await terminal.write('\x03');      // Ctrl+C
await terminal.write('\x1B');      // Escape
await terminal.write('\x7F');      // Backspace
await terminal.write('hello');     // Type text

// Assertions
await expect(terminal.getByText('pattern')).toBeVisible();
await expect(terminal.getByText('pattern', { full: true })).toBeVisible();
await expect(terminal).toMatchSnapshot();

// Reading
const content = terminal.content;  // Full terminal content as string

Running

npx tui-test                       # Run all tests
npx tui-test --update-snapshots    # Update snapshots
npx tui-test my-test.ts            # Run specific test

Reference

  • Used by VS Code terminal team
  • Real PTY isolation per test (no mocking)
  • Auto-waits for terminal renders
  • Cross-platform (macOS, Linux, Windows)
  • Snapshot testing built-in

리뷰

아직 리뷰가 없습니다. 사용해 본 소감을 남겨 주세요.

댓글

로그인 없이 쓸 수 있습니다. 사용 후기, 질문, 작동하지 않은 환경 등을 편하게 남겨 주세요.

아직 댓글이 없습니다. 첫 댓글을 남겨 보세요.

보내면 바로 공개됩니다. 이메일 주소나 전화번호 같은 개인 정보는 쓰지 마세요. URL은 2개까지입니다.

0 / 1,000자

이 양식은 reCAPTCHA로 보호되며 Google 개인정보처리방침 및 서비스 약관이 적용됩니다.

같은 저장소의 스킬

Automate real browser tasks to test websites, complete forms, and collect page information. The skill guides agents through identifying clickable elements, interacting with pages, comparing page states, and saving screenshots or PDFs.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Testing form submissions and page navigation
  • Comparing page appearance before and after changes
  • Extracting page text and saving PDFs
slopus/happy2.4만2026년 10월 19일 업데이트

Trace application behavior and explain data structures using compact text tree diagrams. The diagrams connect user actions to real functions, data types, state changes, and the components that render again as a result.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Tracing what happens after a user action
  • Investigating why a component renders again
  • Mapping data structures and their consumers
slopus/happy2.4만2026년 10월 19일 업데이트

dev

무료

Set up and run Happy components locally, including its CLI, server, mobile app, and desktop app. The guide covers building, testing, checking logs, and separating development data using pnpm, the project's package management tool.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Setting up a local Happy development environment
  • Rebuilding the CLI and checking its daemon
  • Running the server and app locally
slopus/happy2.4만2026년 10월 19일 업데이트

maintain

무료

Organize Happy's GitHub issues, find duplicates, and check whether reported bugs are fixed on main, the primary development branch. Prepare replies and proposed actions for maintainer review, with explicit approval required before changes affecting contributors.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Grouping open issues and identifying duplicates
  • Checking whether reported bugs are fixed on main
  • Drafting replies and issue closure comments
slopus/happy2.4만2026년 10월 19일 업데이트

Query Prometheus metrics through Grafana and manage dashboards as JSON files. Use it to investigate current values and trends, add or adjust panels, and preview dashboard updates before applying them.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Investigating error rates and response times
  • Adding panels to a Grafana dashboard
  • Managing dashboard configuration as JSON
slopus/happy2.4만2026년 10월 19일 업데이트

Develop a product or side-project idea through guided questions and premise checks. Startup discussions examine evidence of demand, while builder discussions explore possibilities and scope, producing a design document before implementation begins.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Examining demand for a startup idea
  • Defining the smallest useful internal project
  • Shaping a hackathon or side-project idea
slopus/happy2.4만2026년 10월 19일 업데이트

slopus의 스킬 모두 보기

이 스킬의 문제 신고