AGENT SKILL

run-tests

How to run tests in this project. Load when implementing or verifying code.

License 许可
MIT
最近更新
2026-06-24
Stars
★ 67
Forks
24

01 前言 Front Matter

name
run-tests
description
How to run tests in this project. Load when implementing or verifying code.
allowed-tools
Bash

02 资源文件 3

03 SKILL.md 正文

Run Tests Skill

Project-specific test execution.

Test Commands

# Run all tests
# TODO: Add your test command
npm test
# pytest
# go test ./...
# cargo test

# Run specific file
# TODO: Add your pattern
npm test -- --testPathPattern={file}
# pytest {file} -v

# Run affected tests
npm test -- --changedSince=HEAD

Test Patterns

  • Test files: **/*.test.ts or **/__tests__/*.ts
  • Test naming: describe('Component', () => { it('should...') })

Coverage

# Run with coverage
npm test -- --coverage

Debugging Failed Tests

  1. Read the error message
  2. Check the test file
  3. Check the source file
  4. Run single test in isolation

04 同仓库更多 Skills