Przejdź do treści
Biblioteka skilli
Programowanie · Analiza

qe-coverage-analysis

/qe-coverage-analysis

Analizuje dane pokrycia testami (Istanbul, c8, lcov), wskazuje niepokryte linie, gałęzie i funkcje z wagą ryzyka oraz porównuje pokrycie między gałęziami.

Repozytorium
agentic-qe ↗
Licencja
MIT
Ostatnia zmiana repozytorium
25.10.2026

Ocena i bezpieczeństwo

100/ 100Klasa: dobry
Format25 / 25
Frontmatter z nazwą i opisem, poprawna nazwa, opis do 1024 znaków, nazwa zgodna z folderem.
Odkrywalność25 / 25
Opis mówi, kiedy użyć skilla, ma sensowną długość i jest w 3. osobie.
Treść35 / 35
Co najmniej 150 słów i do 500 linii, nagłówki, listy kroków, przykłady albo kod.
Higiena15 / 15
Bez zaślepek typu TODO, bez ścieżek Windows, z licencją.
Ryzykobrak sygnałów w skanie
Pliki w paczce
4
Skrypty
0
Komentarze HTML
0
Adresy URL w SKILL.md
0
Przestarzałość

Brak sygnałów. Repozytorium zmienione 25.10.2026, bez odwołań do wycofanych modeli i API.

Licencja

MIT, otwarta: można używać i zmieniać, z zachowaniem informacji o autorze.

Co robi i kiedy

Analizuje dane pokrycia testami (Istanbul, c8, lcov), wskazuje niepokryte linie, gałęzie i funkcje z wagą ryzyka oraz porównuje pokrycie między gałęziami.

Oryginalny opis (EN)

Analyzes test coverage data (Istanbul, c8, lcov) to identify uncovered lines, branches, and functions with risk-weighted gap detection. Use when analyzing coverage reports, identifying coverage gaps, comparing coverage between branches, or prioritizing which untested code to cover first.

Jak działa

  1. Purpose
  2. Activation
  3. Quick Start
  4. Agent Workflow
  5. Analysis Strategies
  6. Coverage Thresholds
  7. Coverage Report
  8. Quality Gates
  9. Run History
  10. Skill Composition
Sekcje z nagłówków SKILL.md, w oryginale · 211 linii, 664 słów
Podgląd SKILL.md
---
name: "qe-coverage-analysis"
description: "Analyzes test coverage data (Istanbul, c8, lcov) to identify uncovered lines, branches, and functions with risk-weighted gap detection. Use when analyzing coverage reports, identifying coverage gaps, comparing coverage between branches, or prioritizing which untested code to cover first."
trust_tier: 3
allowed-tools:
  - Read
  - Bash
  - Grep
  - Glob
  - mcp__plugin_agentic-qe-fleet_agentic-qe__coverage_analyze_sublinear
  - mcp__agentic-qe__coverage_analyze_sublinear
  - mcp__plugin_agentic-qe-fleet_agentic-qe__qe_coverage_gaps
  - mcp__agentic-qe__qe_coverage_gaps
validation:
  schema_path: schemas/output.json
  validator_path: scripts/validate-config.json
  eval_path: evals/qe-coverage-analysis.yaml
---

# QE Coverage Analysis

## Purpose

Guide the use of v3's advanced coverage analysis capabilities including sublinear gap detection algorithms, risk-weighted coverage scoring, and intelligent test prioritization based on code criticality.

## Activation

- When analyzing test coverage
- When identifying coverage gaps
- When prioritizing testing effort
- When setting coverage targets
- When assessing code risk

## Quick Start

```bash
# Analyze coverage with gap detection
aqe coverage analyze --source src/ --tests tests/

# Find high-risk uncovered code
aqe coverage gaps --risk-weighted --threshold 80

# Generate coverage report
aqe coverage report --format html --output coverage-report/

# Compare coverage between branches
aqe coverage diff --base main --head feature-branch
```

## Agent Workflow

```typescript
// Comprehensive coverage analysis
Task("Analyze coverage gaps", `
  Perform O(log n) coverage analysis on src/:
  - Calculate statement, branch, function coverage
  - Identify uncovered critical paths
  - Risk-weight gaps by code complexity and change frequency
  - Recommend tests to write for maximum coverage impact
`, "qe-coverage-specialist")

// Risk-based prioritization
Task("Prioritize coverage effort", `
  Analyze coverage gaps and prioritize by:
  - Business criticality (payment, auth, data)
  - Code complexity (cyclomatic > 10)
  - Recent bug history
  - Change frequency
  Output prioritized list of files needing tests.
`, "qe-coverage-analyzer")
```

## Analysis Strategies

### 1. Sublinear Gap Detection

```typescript
await coverageAnalyzer.detectGaps({
  algorithm: 'sublinear',  // O(log n) complexity
  source: 'src/**/*.ts',
  metrics: ['statement', 'branch', 'function'],
  sampling: {
    enabled: true,
    confidence: 0.95,
    maxSamples: 1000
  }
});
```

### 2. Risk-Weighted Coverage

```typescript
await coverageAnalyzer.riskWeightedAnalysis({
  coverage: coverageReport,
  riskFactors: {
    complexity: { weight: 0.3, threshold: 10 },
    changeFrequency: { weight: 0.25, window: '90d' },
    bugHistory: { weight: 0.25, window: '180d' },
    criticality: { weight: 0.2, tags: ['payment', 'auth'] }
  },
  output: {
    riskScore: true,
    prioritizedGaps: true
  }
});
```

### 3. Differential Coverage

```typescript
await coverageAnalyzer.diffCoverage({
  base: 'main',
  head: 'feature-branch',
  requirements: {
    newCode: 80,           // New code must have 80% coverage
    modifiedCode: 'maintain',  // Don't decrease existing
    deletedCode: 'ignore'
  }
});
```

## Coverage Thresholds

```yaml
thresholds:
  global:
    statements: 80
    branches: 75
    functions: 85
    lines: 80

  per_file:
    min_statements: 70
    critical_paths: 90

  new_code:
    statements: 85
    branches: 80

  exceptions:
    - path: "src/migrations/**"
      reason: "Database migrations"
    - path: "src/generated/**"
      reason: "Auto-generated code"
```

## Coverage Report

```typescript
interface CoverageAnalysis {
  summary: {
    statements: { covered: number; total: number; percentage: number };
    branches: { covered: number; total: number; percentage: number };
    functions: { covered: number; total: number; percentage: number };
  };
  gaps: {
    file: string;
    uncoveredLines: number[];
    uncoveredBranches: BranchInfo[];
    riskScore: number;
    suggestedTests: string[];
  }[];
  trends: {
    period: string;
    coverageChange: number;
    newGaps: number;
    closedGaps: number;
  };
  recommendations: {
    priority: 'critical' | 'high' | 'medium' | 'low';
    file: string;
    action: string;
    expectedImpact: number;
  }[];
}
```

## Quality Gates

```yaml
quality_gates:
  coverage:
    block_merge:
      - new_code_coverage < 80
      - coverage_regression > 5
      - critical_path_uncovered

    warn:
      - overall_coverage < 75
      - branch_coverage < 70

    metrics:
      - track_trends: true
      - alert_on_decline: 3  # consecutive PRs
```

## Run History

After each coverage analysis, append results to `run-history.json` in this skill directory:
```bash
# Read current history, append new entry, write back
node -e "
const fs = require('fs');
const h = JSON.parse(fs.readFileSync('.claude/skills/qe-coverage-analysis/run-history.json'));
h.runs.push({date: new Date().toISOString().split('T')[0], statements_pct: STATEMENTS, branches_pct: BRANCHES, gaps_found: GAPS});
fs.writeFileSync('.claude/skills/qe-coverage-analysis/run-history.json', JSON.stringify(h, null, 2));
"
```
Read `run-history.json` before each run to detect trends (e.g., "coverage dropped 3 consecutive times").

## Skill Composition

- **Coverage dropped?** → Use `/coverage-drop-investigator` to trace the cause
- **Need more tests** → Use `/qe-test-generation` to fill gaps
- **Validate quality** → Use `/mutation-testing` to ensure coverage means quality
- **Ship decision** → Feed into `/qe-quality-assessment` for deployment readiness

## Gotchas

- High line coverage does NOT mean good tests — 100% coverage with 0% assertions is common agent output. Use mutation testing to verify
- coverage-analysis domain has 86% success rate — 14% of runs fail on initialization. Always verify results and have fallback plan (e.g. manual coverage tools)
- Self-learning pipeline may silently stop learning (statusline frozen for days) — only human inspection catches this

## Coordination

**Primary Agents**: qe-coverage-specialist, qe-coverage-analyzer, qe-gap-detector
**Coordinator**: qe-coverage-coordinator
**Related Skills**: qe-test-generation, qe-quality-assessment
Pliki w paczce (4)
  • SKILL.md 6 KB
  • evals/qe-coverage-analysis.yaml 14 KB
  • schemas/output.json 10 KB
  • scripts/validate-config.json 1 KB

Wersje

W bazie nie ma innych skilli o nazwie qe-coverage-analysis.

Identyczna treść występuje jeszcze w 2 innych folderach na GitHubie. Tu pokazujemy jedną, najlepiej ocenioną kopię.

Migawka bazy z 13.11.2026 · wersja paczki c1c076ac72ed (skrót SHA-256 całej paczki)

Pobrania w ostatnich 30 dniach: 0 · ranking

Zgłoś problem z tym skillem: szkodliwa treść, błędny opis albo prośba autora o usunięcie.

Podobne skille

  • 100analyzing-test-coverage
    Analizuje metryki pokrycia kodu testami i wskazuje nieprzetestowane fragmenty kodu.
  • 100analyzing-test-coverage
    Analizuje metryki pokrycia kodu testami i wskazuje nieprzetestowane fragmenty kodu.
  • 100dart-collect-coverage
    Mierzy pokrycie kodu testami w Dart, generuje raporty LCOV lub HTML i filtruje pliki pokrycia.
  • 100bun-test-coverage
    Mierzy pokrycie testami w Bun przez flagę --coverage: raporty lcov, progi i integracja z CI.
  • 100code-coverage
    Pomaga mierzyć, interpretować i poprawiać pokrycie kodu testami: linii, gałęzi, funkcji, instrukcji, warunków i MC/DC, z narzędziami Istanbul, JaCoCo, coverage.py, Codecov i progami pokrycia.
  • 100run-coverage
    Mierzy pokrycie testami, wskazuje niepokryte gałęzie i dokumentuje wynik, gdy zadanie wyznacza próg pokrycia lub wymaga jego podniesienia, także przy kontroli mutation score.

Uwagi i zgłoszenia

Wiadomość trafi do Bartosza Sokolińskiego. Adres e-mail jest potrzebny tylko do odpowiedzi. Szczegóły w polityce prywatności.