agentic-qe 2.0.0 → 2.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.claude/agents/qx-partner.md +17 -4
- package/.claude/skills/accessibility-testing/SKILL.md +144 -692
- package/.claude/skills/agentic-quality-engineering/SKILL.md +176 -529
- package/.claude/skills/api-testing-patterns/SKILL.md +180 -560
- package/.claude/skills/brutal-honesty-review/SKILL.md +113 -603
- package/.claude/skills/bug-reporting-excellence/SKILL.md +116 -517
- package/.claude/skills/chaos-engineering-resilience/SKILL.md +127 -72
- package/.claude/skills/cicd-pipeline-qe-orchestrator/SKILL.md +209 -404
- package/.claude/skills/code-review-quality/SKILL.md +158 -608
- package/.claude/skills/compatibility-testing/SKILL.md +148 -38
- package/.claude/skills/compliance-testing/SKILL.md +132 -63
- package/.claude/skills/consultancy-practices/SKILL.md +114 -446
- package/.claude/skills/context-driven-testing/SKILL.md +117 -381
- package/.claude/skills/contract-testing/SKILL.md +176 -141
- package/.claude/skills/database-testing/SKILL.md +137 -130
- package/.claude/skills/exploratory-testing-advanced/SKILL.md +160 -629
- package/.claude/skills/holistic-testing-pact/SKILL.md +140 -188
- package/.claude/skills/localization-testing/SKILL.md +145 -33
- package/.claude/skills/mobile-testing/SKILL.md +132 -448
- package/.claude/skills/mutation-testing/SKILL.md +147 -41
- package/.claude/skills/performance-testing/SKILL.md +200 -546
- package/.claude/skills/quality-metrics/SKILL.md +164 -519
- package/.claude/skills/refactoring-patterns/SKILL.md +132 -699
- package/.claude/skills/regression-testing/SKILL.md +120 -926
- package/.claude/skills/risk-based-testing/SKILL.md +157 -660
- package/.claude/skills/security-testing/SKILL.md +199 -538
- package/.claude/skills/sherlock-review/SKILL.md +163 -699
- package/.claude/skills/shift-left-testing/SKILL.md +161 -465
- package/.claude/skills/shift-right-testing/SKILL.md +161 -519
- package/.claude/skills/six-thinking-hats/SKILL.md +175 -1110
- package/.claude/skills/skills-manifest.json +71 -20
- package/.claude/skills/tdd-london-chicago/SKILL.md +131 -448
- package/.claude/skills/technical-writing/SKILL.md +103 -154
- package/.claude/skills/test-automation-strategy/SKILL.md +166 -772
- package/.claude/skills/test-data-management/SKILL.md +126 -910
- package/.claude/skills/test-design-techniques/SKILL.md +179 -89
- package/.claude/skills/test-environment-management/SKILL.md +136 -91
- package/.claude/skills/test-reporting-analytics/SKILL.md +169 -92
- package/.claude/skills/testability-scoring/SKILL.md +172 -538
- package/.claude/skills/testability-scoring/scripts/generate-html-report.js +0 -0
- package/.claude/skills/visual-testing-advanced/SKILL.md +155 -78
- package/.claude/skills/xp-practices/SKILL.md +151 -587
- package/CHANGELOG.md +86 -0
- package/README.md +23 -16
- package/dist/agents/QXPartnerAgent.d.ts +47 -1
- package/dist/agents/QXPartnerAgent.d.ts.map +1 -1
- package/dist/agents/QXPartnerAgent.js +2086 -125
- package/dist/agents/QXPartnerAgent.js.map +1 -1
- package/dist/agents/lifecycle/AgentLifecycleManager.d.ts.map +1 -1
- package/dist/agents/lifecycle/AgentLifecycleManager.js +34 -31
- package/dist/agents/lifecycle/AgentLifecycleManager.js.map +1 -1
- package/dist/cli/commands/init-claude-md-template.d.ts.map +1 -1
- package/dist/cli/commands/init-claude-md-template.js +14 -0
- package/dist/cli/commands/init-claude-md-template.js.map +1 -1
- package/dist/core/SwarmCoordinator.d.ts +180 -0
- package/dist/core/SwarmCoordinator.d.ts.map +1 -0
- package/dist/core/SwarmCoordinator.js +473 -0
- package/dist/core/SwarmCoordinator.js.map +1 -0
- package/dist/core/memory/ReflexionMemoryAdapter.d.ts +109 -0
- package/dist/core/memory/ReflexionMemoryAdapter.d.ts.map +1 -0
- package/dist/core/memory/ReflexionMemoryAdapter.js +306 -0
- package/dist/core/memory/ReflexionMemoryAdapter.js.map +1 -0
- package/dist/core/memory/RuVectorPatternStore.d.ts +28 -0
- package/dist/core/memory/RuVectorPatternStore.d.ts.map +1 -1
- package/dist/core/memory/RuVectorPatternStore.js +70 -0
- package/dist/core/memory/RuVectorPatternStore.js.map +1 -1
- package/dist/core/memory/SparseVectorSearch.d.ts +55 -0
- package/dist/core/memory/SparseVectorSearch.d.ts.map +1 -0
- package/dist/core/memory/SparseVectorSearch.js +130 -0
- package/dist/core/memory/SparseVectorSearch.js.map +1 -0
- package/dist/core/memory/TieredCompression.d.ts +81 -0
- package/dist/core/memory/TieredCompression.d.ts.map +1 -0
- package/dist/core/memory/TieredCompression.js +270 -0
- package/dist/core/memory/TieredCompression.js.map +1 -0
- package/dist/core/memory/index.d.ts +6 -0
- package/dist/core/memory/index.d.ts.map +1 -1
- package/dist/core/memory/index.js +29 -1
- package/dist/core/memory/index.js.map +1 -1
- package/dist/core/metrics/MetricsAggregator.d.ts +228 -0
- package/dist/core/metrics/MetricsAggregator.d.ts.map +1 -0
- package/dist/core/metrics/MetricsAggregator.js +482 -0
- package/dist/core/metrics/MetricsAggregator.js.map +1 -0
- package/dist/core/metrics/index.d.ts +5 -0
- package/dist/core/metrics/index.d.ts.map +1 -0
- package/dist/core/metrics/index.js +11 -0
- package/dist/core/metrics/index.js.map +1 -0
- package/dist/core/optimization/SwarmOptimizer.d.ts +5 -0
- package/dist/core/optimization/SwarmOptimizer.d.ts.map +1 -1
- package/dist/core/optimization/SwarmOptimizer.js +17 -0
- package/dist/core/optimization/SwarmOptimizer.js.map +1 -1
- package/dist/core/orchestration/AdaptiveScheduler.d.ts +190 -0
- package/dist/core/orchestration/AdaptiveScheduler.d.ts.map +1 -0
- package/dist/core/orchestration/AdaptiveScheduler.js +460 -0
- package/dist/core/orchestration/AdaptiveScheduler.js.map +1 -0
- package/dist/core/orchestration/WorkflowOrchestrator.d.ts +13 -0
- package/dist/core/orchestration/WorkflowOrchestrator.d.ts.map +1 -1
- package/dist/core/orchestration/WorkflowOrchestrator.js +32 -0
- package/dist/core/orchestration/WorkflowOrchestrator.js.map +1 -1
- package/dist/core/recovery/CircuitBreaker.d.ts +176 -0
- package/dist/core/recovery/CircuitBreaker.d.ts.map +1 -0
- package/dist/core/recovery/CircuitBreaker.js +382 -0
- package/dist/core/recovery/CircuitBreaker.js.map +1 -0
- package/dist/core/recovery/RecoveryOrchestrator.d.ts +186 -0
- package/dist/core/recovery/RecoveryOrchestrator.d.ts.map +1 -0
- package/dist/core/recovery/RecoveryOrchestrator.js +476 -0
- package/dist/core/recovery/RecoveryOrchestrator.js.map +1 -0
- package/dist/core/recovery/RetryStrategy.d.ts +127 -0
- package/dist/core/recovery/RetryStrategy.d.ts.map +1 -0
- package/dist/core/recovery/RetryStrategy.js +314 -0
- package/dist/core/recovery/RetryStrategy.js.map +1 -0
- package/dist/core/recovery/index.d.ts +8 -0
- package/dist/core/recovery/index.d.ts.map +1 -0
- package/dist/core/recovery/index.js +27 -0
- package/dist/core/recovery/index.js.map +1 -0
- package/dist/core/skills/DependencyResolver.d.ts +99 -0
- package/dist/core/skills/DependencyResolver.d.ts.map +1 -0
- package/dist/core/skills/DependencyResolver.js +260 -0
- package/dist/core/skills/DependencyResolver.js.map +1 -0
- package/dist/core/skills/ManifestGenerator.d.ts +114 -0
- package/dist/core/skills/ManifestGenerator.d.ts.map +1 -0
- package/dist/core/skills/ManifestGenerator.js +449 -0
- package/dist/core/skills/ManifestGenerator.js.map +1 -0
- package/dist/core/skills/index.d.ts +9 -0
- package/dist/core/skills/index.d.ts.map +1 -0
- package/dist/core/skills/index.js +24 -0
- package/dist/core/skills/index.js.map +1 -0
- package/dist/mcp/handlers/chaos/chaos-inject-failure.d.ts +5 -0
- package/dist/mcp/handlers/chaos/chaos-inject-failure.d.ts.map +1 -1
- package/dist/mcp/handlers/chaos/chaos-inject-failure.js +36 -2
- package/dist/mcp/handlers/chaos/chaos-inject-failure.js.map +1 -1
- package/dist/mcp/handlers/chaos/chaos-inject-latency.d.ts +5 -0
- package/dist/mcp/handlers/chaos/chaos-inject-latency.d.ts.map +1 -1
- package/dist/mcp/handlers/chaos/chaos-inject-latency.js +36 -2
- package/dist/mcp/handlers/chaos/chaos-inject-latency.js.map +1 -1
- package/dist/mcp/server.d.ts +9 -9
- package/dist/mcp/server.d.ts.map +1 -1
- package/dist/mcp/server.js +1 -2
- package/dist/mcp/server.js.map +1 -1
- package/dist/types/qx.d.ts +113 -7
- package/dist/types/qx.d.ts.map +1 -1
- package/dist/types/qx.js.map +1 -1
- package/dist/visualization/api/RestEndpoints.js +1 -1
- package/dist/visualization/api/RestEndpoints.js.map +1 -1
- package/package.json +15 -54
|
@@ -1,36 +1,70 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: database-testing
|
|
3
|
-
description: Database schema validation, data integrity testing, migration testing, transaction isolation, and query performance. Use when testing data persistence, ensuring referential integrity, or validating database migrations.
|
|
3
|
+
description: "Database schema validation, data integrity testing, migration testing, transaction isolation, and query performance. Use when testing data persistence, ensuring referential integrity, or validating database migrations."
|
|
4
|
+
category: specialized-testing
|
|
5
|
+
priority: high
|
|
6
|
+
tokenEstimate: 900
|
|
7
|
+
agents: [qe-test-data-architect, qe-test-executor, qe-performance-tester]
|
|
8
|
+
implementation_status: optimized
|
|
9
|
+
optimization_version: 1.0
|
|
10
|
+
last_optimized: 2025-12-02
|
|
11
|
+
dependencies: []
|
|
12
|
+
quick_reference_card: true
|
|
13
|
+
tags: [database, schema, migration, transactions, integrity, sql, performance]
|
|
4
14
|
---
|
|
5
15
|
|
|
6
16
|
# Database Testing
|
|
7
17
|
|
|
8
|
-
|
|
18
|
+
<default_to_action>
|
|
19
|
+
When testing database operations:
|
|
20
|
+
1. VALIDATE schema (tables, columns, constraints exist as expected)
|
|
21
|
+
2. TEST data integrity (unique, foreign key, check constraints)
|
|
22
|
+
3. VERIFY migrations (forward works, rollback works, data preserved)
|
|
23
|
+
4. CHECK transaction isolation (ACID properties, concurrent access)
|
|
24
|
+
5. MEASURE query performance (indexes used, execution time)
|
|
25
|
+
|
|
26
|
+
**Quick DB Testing Checklist:**
|
|
27
|
+
- Schema matches specification
|
|
28
|
+
- Unique constraints prevent duplicates
|
|
29
|
+
- Foreign keys prevent orphaned records
|
|
30
|
+
- Migrations are reversible
|
|
31
|
+
- Transactions roll back on error
|
|
32
|
+
|
|
33
|
+
**Critical Success Factors:**
|
|
34
|
+
- Database bugs cause data loss/corruption (catastrophic)
|
|
35
|
+
- Test migrations in staging before production
|
|
36
|
+
- Transaction tests catch concurrency bugs
|
|
37
|
+
</default_to_action>
|
|
38
|
+
|
|
39
|
+
## Quick Reference Card
|
|
40
|
+
|
|
41
|
+
### When to Use
|
|
42
|
+
- New table/schema creation
|
|
43
|
+
- Migration development
|
|
44
|
+
- Data integrity validation
|
|
45
|
+
- Query performance optimization
|
|
46
|
+
|
|
47
|
+
### Database Test Types
|
|
48
|
+
| Type | Focus | When |
|
|
49
|
+
|------|-------|------|
|
|
50
|
+
| **Schema** | Structure correct | Table creation |
|
|
51
|
+
| **Integrity** | Constraints work | Data operations |
|
|
52
|
+
| **Migration** | Up/down work | Schema changes |
|
|
53
|
+
| **Transaction** | ACID properties | Concurrent access |
|
|
54
|
+
| **Performance** | Query speed | Optimization |
|
|
55
|
+
|
|
56
|
+
### ACID Properties
|
|
57
|
+
| Property | Test Focus |
|
|
58
|
+
|----------|------------|
|
|
59
|
+
| **Atomicity** | All or nothing (rollback on error) |
|
|
60
|
+
| **Consistency** | Constraints always valid |
|
|
61
|
+
| **Isolation** | Concurrent transactions don't interfere |
|
|
62
|
+
| **Durability** | Committed data persists |
|
|
9
63
|
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
Database testing ensures schema correctness, data integrity, transaction safety, and query performance. Critical for preventing catastrophic data issues.
|
|
64
|
+
---
|
|
13
65
|
|
|
14
66
|
## Schema Testing
|
|
15
67
|
|
|
16
|
-
**Validate database structure:**
|
|
17
|
-
```sql
|
|
18
|
-
-- Test schema exists
|
|
19
|
-
SELECT table_name FROM information_schema.tables
|
|
20
|
-
WHERE table_schema = 'public' AND table_name = 'users';
|
|
21
|
-
|
|
22
|
-
-- Test column types
|
|
23
|
-
SELECT column_name, data_type
|
|
24
|
-
FROM information_schema.columns
|
|
25
|
-
WHERE table_name = 'users';
|
|
26
|
-
|
|
27
|
-
-- Test constraints
|
|
28
|
-
SELECT constraint_name, constraint_type
|
|
29
|
-
FROM information_schema.table_constraints
|
|
30
|
-
WHERE table_name = 'users';
|
|
31
|
-
```
|
|
32
|
-
|
|
33
|
-
**Test with code:**
|
|
34
68
|
```javascript
|
|
35
69
|
test('users table has correct schema', async () => {
|
|
36
70
|
const schema = await db.raw(`
|
|
@@ -53,14 +87,14 @@ test('users table has correct schema', async () => {
|
|
|
53
87
|
});
|
|
54
88
|
```
|
|
55
89
|
|
|
90
|
+
---
|
|
91
|
+
|
|
56
92
|
## Data Integrity Testing
|
|
57
93
|
|
|
58
|
-
**Test constraints:**
|
|
59
94
|
```javascript
|
|
60
95
|
test('email must be unique', async () => {
|
|
61
96
|
await db.users.create({ email: 'test@example.com' });
|
|
62
97
|
|
|
63
|
-
// Duplicate should fail
|
|
64
98
|
await expect(
|
|
65
99
|
db.users.create({ email: 'test@example.com' })
|
|
66
100
|
).rejects.toThrow('unique constraint violation');
|
|
@@ -70,72 +104,46 @@ test('foreign key prevents orphaned records', async () => {
|
|
|
70
104
|
const user = await db.users.create({ email: 'test@example.com' });
|
|
71
105
|
await db.orders.create({ userId: user.id, total: 100 });
|
|
72
106
|
|
|
73
|
-
// Cannot delete user with orders
|
|
74
107
|
await expect(
|
|
75
108
|
db.users.delete({ id: user.id })
|
|
76
109
|
).rejects.toThrow('foreign key constraint');
|
|
77
110
|
});
|
|
78
|
-
|
|
79
|
-
test('check constraint validates data', async () => {
|
|
80
|
-
// Age must be ≥ 18
|
|
81
|
-
await expect(
|
|
82
|
-
db.users.create({ email: 'minor@example.com', age: 17 })
|
|
83
|
-
).rejects.toThrow('check constraint violation');
|
|
84
|
-
});
|
|
85
111
|
```
|
|
86
112
|
|
|
113
|
+
---
|
|
114
|
+
|
|
87
115
|
## Migration Testing
|
|
88
116
|
|
|
89
|
-
**Test database migrations:**
|
|
90
117
|
```javascript
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
test('migration adds users table', async () => {
|
|
94
|
-
// Start fresh
|
|
95
|
-
await rollback();
|
|
96
|
-
|
|
97
|
-
// Run migration
|
|
98
|
-
await migrate();
|
|
99
|
-
|
|
100
|
-
// Verify table exists
|
|
101
|
-
const tables = await db.raw(`
|
|
102
|
-
SELECT table_name FROM information_schema.tables
|
|
103
|
-
WHERE table_schema = 'public'
|
|
104
|
-
`);
|
|
118
|
+
test('migration is reversible', async () => {
|
|
119
|
+
await migrate('add-users-table');
|
|
105
120
|
|
|
121
|
+
// Table exists after migration
|
|
122
|
+
const tables = await db.raw(`SELECT table_name FROM information_schema.tables`);
|
|
106
123
|
expect(tables.map(t => t.table_name)).toContain('users');
|
|
107
|
-
});
|
|
108
124
|
|
|
109
|
-
|
|
110
|
-
await migrate();
|
|
111
|
-
await rollback();
|
|
125
|
+
await rollback('add-users-table');
|
|
112
126
|
|
|
113
|
-
// Table
|
|
114
|
-
const
|
|
115
|
-
|
|
116
|
-
WHERE table_schema = 'public'
|
|
117
|
-
`);
|
|
118
|
-
|
|
119
|
-
expect(tables.map(t => t.table_name)).not.toContain('users');
|
|
127
|
+
// Table gone after rollback
|
|
128
|
+
const tablesAfter = await db.raw(`SELECT table_name FROM information_schema.tables`);
|
|
129
|
+
expect(tablesAfter.map(t => t.table_name)).not.toContain('users');
|
|
120
130
|
});
|
|
121
131
|
|
|
122
132
|
test('migration preserves existing data', async () => {
|
|
123
|
-
// Create data before migration
|
|
124
133
|
await db.users.create({ email: 'test@example.com' });
|
|
125
134
|
|
|
126
|
-
// Run migration that adds 'age' column
|
|
127
135
|
await migrate('add-age-column');
|
|
128
136
|
|
|
129
|
-
// Data should still exist
|
|
130
137
|
const user = await db.users.findOne({ email: 'test@example.com' });
|
|
131
138
|
expect(user).toBeDefined();
|
|
132
139
|
expect(user.age).toBeNull(); // New column, null default
|
|
133
140
|
});
|
|
134
141
|
```
|
|
135
142
|
|
|
136
|
-
|
|
143
|
+
---
|
|
144
|
+
|
|
145
|
+
## Transaction Testing
|
|
137
146
|
|
|
138
|
-
**Test ACID properties:**
|
|
139
147
|
```javascript
|
|
140
148
|
test('transaction rolls back on error', async () => {
|
|
141
149
|
const initialCount = await db.users.count();
|
|
@@ -144,94 +152,93 @@ test('transaction rolls back on error', async () => {
|
|
|
144
152
|
await db.transaction(async (trx) => {
|
|
145
153
|
await trx('users').insert({ email: 'user1@example.com' });
|
|
146
154
|
await trx('users').insert({ email: 'user2@example.com' });
|
|
147
|
-
|
|
148
|
-
// Force error
|
|
149
155
|
throw new Error('Rollback test');
|
|
150
156
|
});
|
|
151
|
-
} catch (error) {
|
|
152
|
-
// Expected
|
|
153
|
-
}
|
|
157
|
+
} catch (error) { /* Expected */ }
|
|
154
158
|
|
|
155
|
-
|
|
156
|
-
const finalCount = await db.users.count();
|
|
157
|
-
expect(finalCount).toBe(initialCount);
|
|
159
|
+
expect(await db.users.count()).toBe(initialCount);
|
|
158
160
|
});
|
|
159
161
|
|
|
160
|
-
test('concurrent transactions
|
|
161
|
-
const user = await db.users.create({
|
|
162
|
-
|
|
163
|
-
// Two concurrent withdrawals
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
162
|
+
test('concurrent transactions isolated', async () => {
|
|
163
|
+
const user = await db.users.create({ balance: 100 });
|
|
164
|
+
|
|
165
|
+
// Two concurrent withdrawals (race condition test)
|
|
166
|
+
await Promise.all([
|
|
167
|
+
db.transaction(async (trx) => {
|
|
168
|
+
const current = await trx('users').where({ id: user.id }).first();
|
|
169
|
+
await trx('users').update({ balance: current.balance - 50 });
|
|
170
|
+
}),
|
|
171
|
+
db.transaction(async (trx) => {
|
|
172
|
+
const current = await trx('users').where({ id: user.id }).first();
|
|
173
|
+
await trx('users').update({ balance: current.balance - 50 });
|
|
174
|
+
})
|
|
175
|
+
]);
|
|
171
176
|
|
|
172
|
-
const withdraw2 = db.transaction(async (trx) => {
|
|
173
|
-
const current = await trx('users').where({ id: user.id }).first();
|
|
174
|
-
await sleep(100);
|
|
175
|
-
await trx('users').where({ id: user.id }).update({
|
|
176
|
-
balance: current.balance - 50
|
|
177
|
-
});
|
|
178
|
-
});
|
|
179
|
-
|
|
180
|
-
await Promise.all([withdraw1, withdraw2]);
|
|
181
|
-
|
|
182
|
-
// With proper isolation, balance should be 0, not 50
|
|
183
177
|
const final = await db.users.findOne({ id: user.id });
|
|
184
|
-
expect(final.balance).toBe(0); //
|
|
178
|
+
expect(final.balance).toBe(0); // Proper isolation
|
|
185
179
|
});
|
|
186
180
|
```
|
|
187
181
|
|
|
188
|
-
|
|
182
|
+
---
|
|
189
183
|
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
184
|
+
## Agent-Driven Database Testing
|
|
185
|
+
|
|
186
|
+
```typescript
|
|
187
|
+
// Generate test data with integrity
|
|
188
|
+
await Task("Generate Test Data", {
|
|
189
|
+
schema: 'ecommerce',
|
|
190
|
+
tables: ['users', 'products', 'orders'],
|
|
191
|
+
count: { users: 1000, products: 500, orders: 5000 },
|
|
192
|
+
preserveReferentialIntegrity: true
|
|
193
|
+
}, "qe-test-data-architect");
|
|
194
|
+
|
|
195
|
+
// Test migration safety
|
|
196
|
+
await Task("Migration Test", {
|
|
197
|
+
migration: 'add-payment-status-column',
|
|
198
|
+
tests: ['forward', 'rollback', 'data-preservation'],
|
|
199
|
+
environment: 'staging'
|
|
200
|
+
}, "qe-test-executor");
|
|
201
|
+
```
|
|
195
202
|
|
|
196
|
-
|
|
197
|
-
await db.users.findOne({ email: 'user5000@example.com' });
|
|
198
|
-
const duration = Date.now() - start;
|
|
203
|
+
---
|
|
199
204
|
|
|
200
|
-
|
|
201
|
-
expect(duration).toBeLessThan(10); // < 10ms
|
|
202
|
-
});
|
|
205
|
+
## Agent Coordination Hints
|
|
203
206
|
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
207
|
+
### Memory Namespace
|
|
208
|
+
```
|
|
209
|
+
aqe/database-testing/
|
|
210
|
+
├── schema-snapshots/* - Current schema state
|
|
211
|
+
├── migrations/* - Migration test results
|
|
212
|
+
├── integrity/* - Constraint validation
|
|
213
|
+
└── performance/* - Query benchmarks
|
|
214
|
+
```
|
|
208
215
|
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
216
|
+
### Fleet Coordination
|
|
217
|
+
```typescript
|
|
218
|
+
const dbFleet = await FleetManager.coordinate({
|
|
219
|
+
strategy: 'database-testing',
|
|
220
|
+
agents: [
|
|
221
|
+
'qe-test-data-architect', // Generate test data
|
|
222
|
+
'qe-test-executor', // Run DB tests
|
|
223
|
+
'qe-performance-tester' // Query performance
|
|
224
|
+
],
|
|
225
|
+
topology: 'sequential'
|
|
213
226
|
});
|
|
214
227
|
```
|
|
215
228
|
|
|
229
|
+
---
|
|
230
|
+
|
|
216
231
|
## Related Skills
|
|
232
|
+
- [test-data-management](../test-data-management/) - Generate test data
|
|
233
|
+
- [performance-testing](../performance-testing/) - Query performance
|
|
234
|
+
- [compliance-testing](../compliance-testing/) - Data protection
|
|
217
235
|
|
|
218
|
-
|
|
219
|
-
- [performance-testing](../performance-testing/) - DB performance testing
|
|
220
|
-
- [test-automation-strategy](../test-automation-strategy/) - Automate DB tests
|
|
236
|
+
---
|
|
221
237
|
|
|
222
238
|
## Remember
|
|
223
239
|
|
|
224
|
-
**Database bugs are catastrophic.**
|
|
225
|
-
|
|
226
|
-
- Data loss is unrecoverable
|
|
227
|
-
- Corruption spreads silently
|
|
228
|
-
- Performance issues compound
|
|
229
|
-
- Migrations must be reversible
|
|
240
|
+
**Database bugs are catastrophic.** Data loss is unrecoverable. Corruption spreads silently. Performance issues compound.
|
|
230
241
|
|
|
231
|
-
**Test migrations before production:**
|
|
232
|
-
- Forward migration works
|
|
233
|
-
- Backward rollback works
|
|
234
|
-
- Data preserved/migrated correctly
|
|
235
|
-
- Performance acceptable
|
|
242
|
+
**Test migrations before production:** Forward works, rollback works, data preserved, performance acceptable. Never deploy untested migrations.
|
|
236
243
|
|
|
237
|
-
**With Agents:** `qe-test-data-architect` generates realistic test data with referential integrity. `qe-test-executor`
|
|
244
|
+
**With Agents:** `qe-test-data-architect` generates realistic test data with referential integrity. `qe-test-executor` validates migrations automatically in CI/CD.
|