/ancplua-skills:test-audit <area> [target, e.g. remove 20% and keep coverage within 2 points]from ancplua-skills
Audit and prune an existing .NET test suite (MSTest on Microsoft.Testing.Platform) by finding tests that restate the implementation, duplicate stronger tests, or keep test-only production seams alive, then removing or consolidating them with evidence. Use when asked to audit, clean up, prune, dedupe, or consolidate tests, to cut test count against a coverage target, or to judge whether tests earn their keep.
Ships in ancplua-skills. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
Scope and target: $ARGUMENTS
New tests are gated by the authoring rules in CLAUDE.md; this skill sweeps existing ones. Optimize for confidence per maintained line, not for deletion count.
Written against MSTest.Sdk 4.4.1 on Microsoft.Testing.Platform 2.4.1 (API docs: view=mstest-net-4.4).
Record the commit, dirty files and dotnet --version, then run the full suite once:
dotnet test <solution or project> --report-trx --coverage --coverage-output-format cobertura --results-directory <dir>
Keep the executed test count and the line-rate and branch-rate attributes of the cobertura root. Compare later runs in percentage points, with the same command on the same machine.
Count tests, not attempts: every [Retry] attempt is reported (failed (try 1) MyTest) while the test counts once; keep the flaky: and retried: summary lines with the baseline. Record what removes tests from the count without a failure: an ITestFilter that returns Drop ([assembly: TestFilterProvider]), a failed [DependsOn] prerequisite, which skips its dependents, and EnableMSTestSourceGeneration, under which a class that only inherits [TestClass] is never discovered (MSTEST0069).
The build's analyzer warnings name the first candidates: MSTEST0074 to MSTEST0077 (tests that mutate process-global state, the current directory, culture or shared files under parallel execution) and MSTEST0082 (inherited tests that MSTest skips silently because their base class was compiled against another MSTest major version).
Read the whole test and its production owner (entry point, callers, sibling tests, git history) before judging it. Candidates:
return or Assert.Inconclusive on the architecture, the CI variable or a missing executable, which reports a pass without testing anything (MSTEST0079, MSTEST0080, MSTEST0083);[DoNotParallelize] or ordering by name around one shared resource ([ResourceLock], [DependsOn]), temporary directories created and deleted by hand (TestContext.TestTempDirectory);[DataRow] grids that spell out every combination (CombinatorialData);Verify(..., Times.Once)) where the effect itself is observable; mocks that implement the asserted behavior; one mock standing in for different APIs;[DataRow]s;Keep a test when it independently guards a public API, a wire format or serialization (e.g. OTLP payloads), config, migrations, storage, security, AOT or trimming behavior, source-generator output, platform behavior, defaults, observable ordering, or a regression with a credible failure mode. Resembling the implementation isn't enough to delete it: show the contract is guarded elsewhere first. Slow or static isn't a reason either. A retained test that fails on the baseline is a possible product bug; reproduce and report it rather than deleting it.
Test name and location; the failure it can actually detect; the stronger remaining test that detects it (by name), or why none is needed; non-test callers of any seam it keeps alive; history (git log -S, blame) and why it exists; what deleting it unlocks; risk and the focused validation command.
One coherent owner-boundary batch per commit. Delete test-only seams together with their tests instead of keeping aliases. Fold near-duplicates into [DataRow]s. Turn guard-and-return tests into [ArchitectureCondition], [CICondition] or [ExecutableCondition], so that they report skipped; their analyzers carry code fixes. Prefer net-negative production LOC. Don't add replacement tests that restate the same implementation.
dotnet test --project <proj> --filter "<expr>" --minimum-expected-tests <n>.ancplua-lean-proof:skeptic subagent.git diff --check, and report production and test LOC separately (git diff --numstat).Removed categories with counts, seams deleted, retained false positives and why, baseline vs after (tests executed, line %, branch %, mutants killed), commands run, follow-ups. Commit, push or open PRs only when authorized.
What SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub ancplua/ancplua-skills --plugin ancplua-skills43 skills in this plugin
/agent-log-scanScan agent transcripts and turn antipatterns into config and routine changes, not just an allowlist like fewer-permission-prompts. Use when asked to scan agent logs or session history, "why do my agents keep failing", "what happened across my sessions", to find retry loops, permission thrash, API dead-ends or limit interrupts, or raise autonomy./analyzer-purityKeep Roslyn analyzers, source generators and code fixes pure, loadable and cache-friendly inside every compiler host. Use when creating, changing, reviewing or packaging a netstandard2.0 project with IsRoslynComponent, EnforceExtendedAnalyzerRules or Microsoft.CodeAnalysis references, or when an RS1xxx/RS2xxx diagnostic, a sluggish IDE or a generator that reruns on every keystroke points at one./Other plugins' skills for the same job