Skip to content
Development
Command

/test-tdd

Run when user calls /test-tdd. Scans modified files, locates their corresponding unit/integration test suites, and runs them.

From plugin
open-agent-hub
1k3 skills5 agents3 commands6 MCP
> /plugin marketplace add guanyang/open-agent-hub
> /plugin install open-agent-hub@open-agent-hub

Command definition

test-tdd.md
name: test-tdd
description: Run when user calls /test-tdd. Scans modified files, locates their corresponding unit/integration test suites, and runs them.
type: command

Slash Command: /test-tdd

Core Objective

Locate and execute the test suites corresponding to modified files.

Steps for the Agent

1. **Identify Modified Code**: Run `git status` or `git diff --name-only` to identify source code files that have changed. 2. **Find Matching Tests**: Search for matching test files in the project. For example:

  • `foo.js` ➔ search for `foo.test.js`, `foo.spec.js`, `test_foo.js` in `test/`, `spec/`, or local directories.

3. **Deduce Test Command**: Determine the correct command runner based on `package.json` scripts or file types (e.g., `npm test -- <file>`, `npx jest <file>`, `pytest <file>`, `go test <file>`). 4. **Execute**: Run the test command and display the execution results. 5. **Loop Strategy**:

  • If tests fail, suggest invoking [agent-debugger](../agents/agent-debugger.md) to inspect stack traces.
@guanyang
Ships withopen-agent-hub

A lightweight, zero-dependency CLI tool to manage and activate capabilities for AI coding assistants (such as Claude Code, Cursor, Trae, etc.).

1k105 skills5 agents6 MCP
Get the whole plugin

Stars on GitHub

Momentum

stars in total
1.0k
Star history of guanyang/open-agent-hub on GitHub, a chart by star-history.com

Other commands on open-agent-hub.

commit

commit

Command

Run when user calls /commit or asks to generate a commit message. Analyzes staged changes and writes a structured commit message.

review

review

Command

Run when user calls /review. Analyzes local changes and runs a comprehensive code review using the agent-reviewer prompt.

More commands from other plugins.

build
Auto-invoked

build

Command

Implement tasks incrementally — build, test, verify, commit. Add "auto" to run the whole plan in one approved pass.

@addyosmani@addyosmaniInstall Command