tests

Enforce standardized unit and integration test organization and execution with bun x jest.

2.0k|126|Updated Sep 17, 2025
One-click install
npx skills add https://github.com/coder/mux --skill tests-coder
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: tests
Source: https://github.com/coder/mux/tree/main/.mux/skills/tests
Command: npx skills add https://github.com/coder/mux --skill tests-coder

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Teams often struggle to maintain consistent testing conventions across projects, leading to flaky results and fragmented coverage.

Core Features & Use Cases

  • Documentation-driven testing: provides a clear doctrine for how tests should be organized, named, and executed.
  • Structured test layout: promotes colocated unit tests (*.test.ts[x]) with source code and centralized integration test locations.
  • Use Case: in multi-repo environments, apply these guidelines to ensure uniform test practices and reliable CI workflows.

Quick Start

Run the test suite using bun x jest with TEST_INTEGRATION=1, following the conventions described above.

Frequently Asked Questions about tests

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

FAQPage Schema
How do I organize unit and integration tests in a codebase?▼

Unit tests should be colocated with source code as *.test.ts[x] files, while integration tests must live in a centralized tests/ directory to maintain structured test layouts.

What is the standard way to execute integration tests with bun and jest?▼

Run the test suite using bun x jest with the TEST_INTEGRATION=1 environment variable set to execute integration tests reliably within your CI workflows.

Does this testing workflow support e2e and ui test harnesses?▼

Yes, the testing guidelines apply to projects with established harnesses for ipc, ui, and e2e tests located alongside source code in the tests/ directory.

Why do I need standardized testing conventions across multiple repositories?▼

Standardized testing conventions prevent flaky results and fragmented coverage in multi-repo environments by enforcing uniform test practices and reliable CI workflows.

When should I colocate unit tests versus using a centralized tests directory?▼

Colocate unit tests as *.test.ts[x] files directly with source code for localized coverage, and place integration tests in the centralized tests/ directory for broader workflow validation.