home / skills / proffesor-for-testing / agentic-qe / xp-practices

xp-practices skill

/v3/assets/skills/xp-practices

This skill helps teams adopt XP practices like TDD, CI, and pairing to improve code quality, collaboration, and sustainable delivery.

npx playbooks add skill proffesor-for-testing/agentic-qe --skill xp-practices

Review the files below or copy the command above to add this skill to your agents.

Files (1)
SKILL.md
6.3 KB
---
name: xp-practices
description: "Apply XP practices including pair programming, ensemble programming, continuous integration, and sustainable pace. Use when implementing agile development practices, improving team collaboration, or adopting technical excellence practices."
category: methodology
priority: medium
tokenEstimate: 1000
agents: [qe-quality-analyzer, qe-test-executor, qe-code-reviewer]
implementation_status: optimized
optimization_version: 1.0
last_optimized: 2025-12-03
dependencies: []
quick_reference_card: true
tags: [xp, agile, pair-programming, tdd, continuous-integration, collaboration]
---

# Extreme Programming (XP) Practices

<default_to_action>
When applying XP practices:
1. START with practices that give immediate value
2. BUILD supporting practices gradually
3. ADAPT to your context
4. MEASURE results

**Core XP Practices (Prioritized):**
| Practice | Start Here | Why First |
|----------|------------|-----------|
| TDD | ✅ Yes | Foundation for everything |
| Continuous Integration | ✅ Yes | Fast feedback |
| Pair Programming | ✅ Yes | Knowledge sharing |
| Collective Ownership | After CI+TDD | Needs safety net |
| Small Releases | After CI | Infrastructure dependent |

**Pairing Quick Start:**
```
Driver-Navigator (Classic):
- Driver: Writes code
- Navigator: Reviews, thinks ahead
- Rotate every 20-30 min

Ping-Pong (with TDD):
A: Write failing test
B: Make test pass + refactor
B: Write next failing test
A: Make test pass + refactor
```
</default_to_action>

## Quick Reference Card

### The Five XP Values

| Value | Meaning | Practice |
|-------|---------|----------|
| **Communication** | Everyone knows what everyone does | Daily standups, pairing |
| **Simplicity** | Simplest thing that works | YAGNI, small design |
| **Feedback** | Get feedback early and often | TDD, CI, short iterations |
| **Courage** | Tell truth, adapt | Refactor, admit mistakes |
| **Respect** | Everyone contributes value | Sustainable pace, pairing |

### Core Practices

| Practice | Description | Benefit |
|----------|-------------|---------|
| **Pair Programming** | Two devs, one workstation | Quality + knowledge sharing |
| **TDD** | Red-Green-Refactor | Confidence + design |
| **CI** | Integrate multiple times/day | Fast feedback |
| **Collective Ownership** | Anyone can change anything | No bottlenecks |
| **Sustainable Pace** | 40-hour weeks | Long-term productivity |
| **Small Releases** | Ship frequently | Risk reduction |

---

## Pair Programming

### When to Pair

| Context | Pair? | Why |
|---------|-------|-----|
| Complex/risky code | ✅ Always | Needs multiple perspectives |
| New technology | ✅ Always | Learning accelerator |
| Onboarding | ✅ Always | Knowledge transfer |
| Critical bugs | ✅ Always | Two heads better |
| Simple tasks | ❌ Skip | Not worth overhead |
| Research spikes | ❌ Skip | Pair to discuss findings |

### Pairing Dos and Don'ts

**Do:**
- ✅ Switch roles every 20-30 min
- ✅ Take breaks together
- ✅ Think out loud
- ✅ Ask questions
- ✅ Keep sessions 2-4 hours max

**Don't:**
- ❌ Grab keyboard without asking
- ❌ Check phone while pairing
- ❌ Dominate conversation
- ❌ Pair all day (exhausting)

---

## Ensemble (Mob) Programming

**Setup:** 3+ developers, one screen, rotating driver

```
[Screen]
   ↓
[Driver] ← Directions from navigators
   ↑
[Navigator 1] [Navigator 2] [Navigator 3]
```

**Rotation:** Driver switches every 5-10 min

**Best for:**
- Complex problem solving
- Architectural decisions
- Learning new frameworks
- Resolving blockers

---

## Continuous Integration

**CI Workflow:**
```
1. Pull latest from main
2. Make small change (<2 hrs work)
3. Run tests locally (all pass)
4. Commit and push
5. CI runs tests automatically
6. If fail → fix immediately
```

**Best Practices:**
- Commit frequently (small changes)
- Keep build fast (<10 min)
- Fix broken builds immediately
- Never commit to broken build

---

## Four Rules of Simple Design

(In priority order)
1. **Passes all tests** - Works correctly
2. **Reveals intention** - Clear, expressive code
3. **No duplication** - DRY principle
4. **Fewest elements** - No speculative code

---

## Agent Integration

```typescript
// Agent-human pair testing
const charter = "Test payment edge cases";
const tests = await Task("Generate Tests", { charter }, "qe-test-generator");
const reviewed = await human.review(tests);
await Task("Implement", { tests: reviewed }, "qe-test-generator");

// Continuous integration with agents
await Task("Risk Analysis", { prDiff }, "qe-regression-risk-analyzer");
await Task("Generate Tests", { changes: prDiff }, "qe-test-generator");
await Task("Execute Tests", { scope: 'affected' }, "qe-test-executor");

// Sustainable pace: agents handle grunt work
const agentWork = ['regression', 'data-generation', 'coverage-analysis'];
const humanWork = ['exploratory', 'risk-assessment', 'strategy'];
```

---

## Agent Coordination Hints

### Memory Namespace
```
aqe/xp-practices/
├── pairing-sessions/*   - Pair/ensemble session logs
├── ci-metrics/*         - CI health metrics
├── velocity/*           - Team velocity data
└── retrospectives/*     - XP retrospective notes
```

### Fleet Coordination
```typescript
const xpFleet = await FleetManager.coordinate({
  strategy: 'xp-workflow',
  agents: [
    'qe-test-generator',   // TDD support
    'qe-test-executor',    // CI integration
    'qe-code-reviewer'     // Collective ownership
  ],
  topology: 'parallel'
});
```

---

## Common Objections

| Objection | Response |
|-----------|----------|
| "Pairing is 2x slower" | 15% slower writing, 15% fewer bugs, net positive |
| "No time for TDD" | Debugging takes longer than testing |
| "CI is hard to setup" | Start simple: one action, one test |
| "Collective ownership = chaos" | Only without tests + CI |

---

## Related Skills
- [tdd-london-chicago](../tdd-london-chicago/) - TDD deep dive
- [refactoring-patterns](../refactoring-patterns/) - Safe refactoring
- [pair-programming](../pair-programming/) - AI-assisted pairing

---

## Remember

**XP practices work as a system.** Don't cherry-pick randomly:
- TDD enables collective ownership
- CI enables small releases
- Pairing enables collective ownership
- Sustainable pace enables everything

**With Agents:** Agents amplify XP. Pair humans with agents. Agents handle repetitive work, humans provide judgment and creativity.

Overview

This skill applies core Extreme Programming (XP) practices—pair programming, ensemble programming, continuous integration, test-driven development, collective ownership, and sustainable pace—to teams and agentic workflows. It helps teams adopt proven agile engineering habits, improve collaboration, and accelerate feedback loops while using agents to remove repetitive work. Use it to design a pragmatic rollout of XP practices tailored to your context.

How this skill works

The skill provides prioritized XP practices and actionable patterns: start with TDD and CI, add pairing/ensembles for knowledge transfer, and introduce collective ownership and small releases once safety nets exist. It includes pairing modes (driver-navigator, ping-pong), ensemble rotation rules, a CI workflow checklist, and agent coordination hints so agents handle grunt tasks while humans focus on strategy. Metrics and memory namespaces support measurement and continuous improvement.

When to use it

  • Onboard new engineers or spread knowledge across the team
  • Introducing or improving CI and fast feedback loops
  • Adopting TDD or making testing the team’s foundation
  • Solving complex design or architectural problems collaboratively
  • Automating repetitive QA tasks via agents to preserve human focus

Best practices

  • Start with practices that give immediate value (TDD, CI, pairing) before expanding
  • Keep CI fast (<10 minutes) and fix broken builds immediately
  • Rotate driver roles frequently (20–30 min for pairs, 5–10 min for mobs)
  • Limit pairing/ensemble sessions to productive windows (2–4 hours max)
  • Measure effects (CI health, velocity, defect rate) and adapt incrementally

Example use cases

  • Pair a senior and junior engineer to onboard via driver-navigator sessions
  • Run ping-pong TDD for a risky feature to ensure design and test coverage
  • Use an ensemble to resolve a cross-cutting architectural decision
  • Integrate agents to generate and run regression tests in CI for every PR
  • Assign agents to data generation and coverage analysis while humans do exploratory testing

FAQ

Is pairing always necessary?

No. Pairing is most valuable for complex code, onboarding, new tech, and critical bugs; skip for small routine tasks where overhead outweighs benefit.

How do agents fit into XP practices?

Agents handle repetitive, deterministic work—test generation, execution, risk analysis—amplifying human judgment for exploratory testing, strategy, and risk assessment.