name: ‘step-03b-subagent-isolation’ description: ‘Subagent: Check test isolation (no shared state/dependencies)’ subagent: true
This is an isolated subagent running in parallel with other quality dimension checks.
Your task: Analyze test files for ISOLATION violations only.
Scan test files for isolation issues:
HIGH SEVERITY Violations:
MEDIUM SEVERITY Violations:
LOW SEVERITY Violations:
const totalChecks = testFiles.length * checksPerFile;
const failedChecks = violations.length;
const severityWeights = { HIGH: 10, MEDIUM: 5, LOW: 2 };
const totalPenalty = violations.reduce((sum, v) => sum + severityWeights[v.severity], 0);
const score = Math.max(0, 100 - totalPenalty);
{
"dimension": "isolation",
"score": 90,
"max_score": 100,
"grade": "A-",
"violations": [
{
"file": "tests/api/integration.spec.ts",
"line": 15,
"severity": "HIGH",
"category": "test-order-dependency",
"description": "Test depends on previous test creating user record",
"suggestion": "Each test should create its own test data in beforeEach",
"code_snippet": "test('should update user', async () => { /* assumes user exists */ });"
}
],
"passed_checks": 14,
"failed_checks": 1,
"total_checks": 15,
"violation_summary": {
"HIGH": 1,
"MEDIUM": 0,
"LOW": 0
},
"recommendations": [
"Add beforeEach hooks to create test data",
"Add afterEach hooks to cleanup created records",
"Use test.describe.configure({ mode: 'parallel' }) to enforce isolation"
],
"summary": "Tests are well isolated with 1 HIGH severity violation"
}
Subagent completes when:
Subagent terminates here.