aboutsummaryrefslogtreecommitdiffstats
path: root/modules/development/pi-coding-agent/skills/testing/SKILL.md
blob: 4785fe7cbea8c8ab1132f9c1d14544d195fbf159 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
---
name: testing
description: "Figure out the project's existing test strategy, add targeted tests, run the smallest useful test set, then broaden validation."
---

# Testing Skill

Figure out the project's existing test strategy, add targeted tests, run the smallest useful test set, then broaden validation.

## Subagents
When you need to delegate sub‑tasks, use the `pi-subagents` skill.

**Example:** To expand test coverage, assign a **scout** to run the existing unit test suite and report gaps, another **scout** to generate property-based tests for the `parser` module, and an **implementer** to add integration tests for the `api` endpoints while a **reviewer** verifies the new tests pass.

*You may adapt the delegation pattern to fit the exact requirements of the codebase.*

## Process

### 1. Discover
- Find test framework and conventions
- Locate existing test files
- Understand test organization

### 2. Target
- Write tests for the specific change
- Focus on behavior, not implementation
- Cover edge cases and error paths

### 3. Run Small
- Execute only affected tests first
- Use test filtering if available
- Verify new tests pass

### 4. Broaden
- Run full test suite
- Check for flaky tests
- Validate integration points

### 5. Report
- Document what was tested
- Note any skipped tests
- Report coverage gaps