Guchho Test — fast, ESM-first JavaScript and TypeScript testing

Guchho Test Documentation

Fast, ESM-first JavaScript and TypeScript testing framework for the Guchho ecosystem.

#

Guchho Test (@guchho/test) is a lightweight, ESM-first testing framework designed for JavaScript and TypeScript projects. It delivers a familiar describe/it API, a powerful assertion engine, lifecycle hooks, mocks and spies, ESM module mocking, snapshots, coverage reporting, and first-class CLI support — all with minimal dependencies and predictable behavior.

Built for both standalone use and integration with the Guchho build toolchain, Guchho Test runs each test file in isolation, produces deterministic output, and ships with actionable diagnostics.

Start here

#

At a glance

#
import { describe, it, expect } from '@guchho/test';

describe('Calculator', () => {
  it('adds two numbers', () => {
    expect(1 + 2).toBe(3);
  });

  it('handles async operations', async () => {
    const result = await Promise.resolve(42);
    expect(result).toBe(42);
  });
});
# Run all tests
npx guchho-test

# Watch mode for development
npx guchho-test watch

# With coverage
npx guchho-test run --coverage

Features

#
Feature Description
Familiar API Drop-in style describe, it, test, with only, skip, and todo
ESM-first Native ESM support with loader hooks for module mocking
TypeScript ready Zero-config TypeScript and JSX/TSX transformation with inline source maps
Isolated execution Each test file runs in its own worker for true isolation
Powerful mocking Functions, spies, constructors, timers, and full ESM module replacement
Snapshot testing External and inline snapshots with property matchers and diff output
Built-in coverage V8 coverage with per-file and global thresholds, multiple report formats
Watch mode Intelligent reruns based on dependency tracking with interactive filtering
Deterministic output Stable ordering for reliable CI results
Extensible Plugin system for custom reporters and matchers

Requirements

#
  • Node.js: >=20.19.0
  • Module system: ESM ("type": "module") or ESM file extensions (.mjs, .mts)

Getting help

#

Every document in this directory describes implemented behavior. If a feature is not covered here, treat it as unsupported rather than assumed.

Edit this page on GitHub