본문으로 건너뛰기
Skillpedia
테스트5.8k · #14625

coverage-analysis

하는 일

이 스킬은 어떤 줄과 분기가 테스트되었고 어떤 것이 테스트되지 않았는지 보여 주는 .NET 테스트 커버리지 보고서를 설명합니다. 커버리지 수치는 있지만 그 의미와 다음에 무엇을 테스트해야 하는지 알고 싶은 개발자를 위한 스킬입니다.

사용하는 경우

  • ✓.NET 커버리지 보고서가 있고 수치가 실제로 무엇을 보여 주는지 알아야 할 때.
  • ✓커버리지가 더 오르지 않을 때 어떤 코드가 진행을 막는지 알고 싶을 때.
  • ✓목표에 도달하려면 커버리지가 얼마나 더 필요한지 계산해야 할 때.

스킬 링크

https://github.com/dotnet/skills/blob/main/plugins/dotnet-test/skills/coverage-analysis/SKILL.md

복사해서 AI(Claude, ChatGPT, Cursor)에 붙여넣고 지침을 따르도록 요청하세요.

사용 방법

가장 쉬운 방법입니다. 메시지를 복사해 AI에 붙여넣으세요. AI가 스킬을 읽고 지침을 따릅니다.

바로 붙여넣을 수 있는 메시지

Use this skill to help me: https://github.com/dotnet/skills/blob/main/plugins/dotnet-test/skills/coverage-analysis/SKILL.md Read the SKILL.md file at that link and follow its instructions for my task.
AI가 이런 스킬을 알아서 찾아 쓰길 원하시나요?무료 Skillpedia MCP를 설치하세요. 한 줄이면 작업마다 스킬 15,000+개 중에서 검색합니다.1분 만에 설치 →

AI에게 요청하는 예시

“우리 커버리지가 72퍼센트에서 멈췄습니다. 이 보고서를 기준으로 80퍼센트에 도달하지 못하게 막는 코드가 무엇인지 알려 주세요.”

매주 새 스킬 5개. 읽는 데 1분.

작동 방식

에이전트가 제공된 커버리지 데이터를 직접 읽고, 테스트되지 않은 줄과 분기를 찾으며, 각 공백이 목표에 대해 무엇을 뜻하는지 계산합니다.

기술 내용 (원본 SKILL.md)

작성자의 영어 원문을 GitHub에서 그대로 가져왔습니다.

Coverage Analysis

Purpose

Explain what .NET coverage evidence proves, reconcile target arithmetic, and identify the code blocking progress. Add complexity/CRAP ranking only when the user explicitly asks for risk hotspots, CRAP, priorities by risk, or refactoring safety.

When to Use

Use this skill for interpreting supplied .NET line/branch/condition evidence, coverage gaps and plateaus, target arithmetic, or explicit project-wide coverage-backed risk analysis.

When Not to Use

  • Named method, class, or file CRAP/refactoring-safety analysis — use the crap-score skill instead
  • Static source-to-test pairing or listing files with no tests — use find-untested-sources
  • Behavioral or pseudo-mutation gaps in existing tests — use test-gap-analysis
  • Test trait/category distributions or coverage shape by test type — use test-tagging
  • Writing or generating tests — this skill identifies where tests are needed, not write them
  • General test execution unrelated to coverage or CRAP analysis
  • Only collecting .NET coverage or printing a raw percentage with no diagnosis — use run-tests; use native tooling for non-.NET coverage collection or analysis. Interpreting .NET line/branch gaps remains in scope here

Inputs

Input Required Default Description
Project/solution path No Current directory Path to the .NET solution or project
Line coverage threshold No 80% Minimum acceptable line coverage
Branch coverage threshold No 70% Minimum acceptable branch coverage
Existing Cobertura path No Discover only if not supplied Preferred input; never rerun tests when usable
CRAP threshold No 30 Used only for explicit risk/CRAP requests
Hotspot count No 3 Explicit risk requests only; cap at 10 unless the user asks for more

Discover optional inputs from the workspace. Do not ask for a project path when the current directory or a supplied report is sufficient.

Choose the smallest matching path

User intent Required work Do not do
Explain a supplied excerpt, condition, or summary Answer directly from the supplied evidence Tools, CRAP, discovery, report files
Interpret a supplied Cobertura path or diagnose a plateau Read that report, reconcile totals, name all material gaps, answer directly Rerun tests, install tools, compute CRAP, or generate files unless explicitly requested
Rank risk hotspots, compute project-wide CRAP, or assess refactoring safety Use the supplied/existing report, read references/guidelines.md, and compute CRAP before ranking Coverage-only ranking or a full report template unless requested
Analyze coverage when no report exists Invoke run-tests to collect coverage with the repository-compatible runner, then analyze the generated report Choose or execute a test command independently; CRAP unless risk was requested
Produce a full markdown/HTML/CSV report First deliver the direct answer; then read references/output-format.md or references/report-generation.md Report generation before the answer

Words such as analyze coverage, what is blocking coverage, or why is coverage stuck do not by themselves request CRAP. Explicit signals include risk hotspot, CRAP, complexity-weighted priority, safe to refactor, or an equivalent request to combine complexity with coverage.

Existing-data fast path

When the user supplies a coverage excerpt, summary, or valid Cobertura path:

  • Treat it as authoritative input and start there.
  • Do not discover the solution or test projects unless source mapping is necessary.
  • Do not run dotnet test, install ReportGenerator, add a coverage package, or read references/setup-discovery.md or references/report-generation.md.
  • Do not write coverage-analysis.md or create a report directory unless the user requested a saved/full report.
  • For interpretation and plateau questions, parse only the evidence needed to answer. For explicit project-wide risk requests, use the bundled scripts as described in references/guidelines.md.

A failed read/view operation is not proof that a named path does not exist. Classify the failure, then make one targeted existence probe and use a normalized path or alternate reader only for confirmed tool availability, transport, or path-normalization failures and only af

자주 묻는 질문

커버리지를 얻으려고 테스트를 실행하나요?

기본적으로는 아닙니다. 명시적으로 수집을 요청하지 않는 한, 제공된 커버리지 증거를 분석합니다.

위험도 순서로 코드를 정렬하나요?

위험 핫스팟이나 CRAP 분석을 요청했을 때만 그렇게 합니다.

테스트를 쓰나요?

아니요. 테스트가 필요한 곳을 보여 주지만, 테스트 작성은 다른 스킬이 담당합니다.

상세 정보

작성자의 원본 설명

Activation requires either supplied .NET coverage reports/percentages/line, branch, or condition metrics, or an explicit request to collect .NET coverage for analysis. USE FOR: interpreting that evidence, including Cobertura data, partial conditions, plateaus, target arithmetic, project-wide coverage-backed CRAP, and coverage-backed refactoring safety. Analyze supplied reports directly without rerunning tests or installing tools. DO NOT USE FOR: requests with neither coverage evidence nor explicit coverage-collection intent, including hypothetical change-survival questions (use test-gap-analys

repo: dotnet/skills

인기도

GitHub 스타
5.8k
순위
#14625
라이선스
MIT
업데이트
2026. 11. 2.

이 스킬이 유용한가요?

0

로그인 투표하려면 로그인하세요.

댓글

  • …

이 저장소의 다른 스킬

비슷한 스킬