Add exp-test-boilerplate-detection and exp-assertion-quality skills#468
Conversation
|
/evaluate |
Two new experimental skills for dotnet-experimental plugin: - exp-test-boilerplate-detection: Detects duplicate boilerplate patterns across .NET test suites and identifies refactoring opportunities. Categories: repeated construction, assertion patterns, copy-paste methods, duplicated setup/teardown, repeated infrastructure. - exp-assertion-quality: Analyzes assertion variety and depth across .NET test suites. Produces metrics dashboard including assertion count, type spread, trivial %, assertion-free tests, and negative assertion coverage. Both skills include eval.yaml with 3-4 scenarios each (positive, negative, and non-activation) plus test fixtures.
f0ad4b6 to
71f2cae
Compare
There was a problem hiding this comment.
Pull request overview
Adds two new experimental skills under the dotnet-experimental plugin to (1) detect duplicated boilerplate across .NET test suites and (2) evaluate assertion quality/diversity, each with accompanying eval scenarios and fixture projects.
Changes:
- Added
exp-test-boilerplate-detectionskill documentation plus eval.yaml and MSTest fixture suites for “heavy” vs “minimal” boilerplate. - Added
exp-assertion-qualityskill documentation plus eval.yaml and fixture suites representing low-diversity, good-diversity, and assertion-free tests. - Introduced non-activation eval scenarios intended to ensure these skills don’t activate for “write tests from scratch” requests.
Reviewed changes
Copilot reviewed 15 out of 15 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| tests/dotnet-experimental/exp-test-boilerplate-detection/fixtures/minimal-boilerplate/Calculator.Tests/CalculatorTests.cs | Minimal-boilerplate MSTest fixture. |
| tests/dotnet-experimental/exp-test-boilerplate-detection/fixtures/minimal-boilerplate/Calculator.Tests/Calculator.Tests.csproj | MSTest fixture project for minimal-boilerplate scenario. |
| tests/dotnet-experimental/exp-test-boilerplate-detection/fixtures/heavy-boilerplate/OrderService.Tests/OrderService.Tests.csproj | MSTest fixture project for heavy-boilerplate scenario. |
| tests/dotnet-experimental/exp-test-boilerplate-detection/fixtures/heavy-boilerplate/OrderService.Tests/OrderProcessorTests.cs | Heavy-boilerplate MSTest fixture with repeated setup and assertions. |
| tests/dotnet-experimental/exp-test-boilerplate-detection/eval.yaml | Eval scenarios for boilerplate detection (heavy/minimal/non-activation). |
| tests/dotnet-experimental/exp-assertion-quality/fixtures/low-diversity/PaymentService.Tests/PaymentService.Tests.csproj | MSTest fixture project for low-diversity assertions. |
| tests/dotnet-experimental/exp-assertion-quality/fixtures/low-diversity/PaymentService.Tests/PaymentProcessorTests.cs | Low-diversity assertion fixture (mostly AreEqual). |
| tests/dotnet-experimental/exp-assertion-quality/fixtures/good-diversity/UserService.Tests/UserService.Tests.csproj | MSTest fixture project for good-diversity assertions. |
| tests/dotnet-experimental/exp-assertion-quality/fixtures/good-diversity/UserService.Tests/UserManagerTests.cs | Good-diversity assertion fixture with null/exception/collection assertions. |
| tests/dotnet-experimental/exp-assertion-quality/fixtures/assertion-free/SmokeTests/SmokeTests.csproj | MSTest fixture project for assertion-free/trivial assertions. |
| tests/dotnet-experimental/exp-assertion-quality/fixtures/assertion-free/SmokeTests/ApiEndpointSmokeTests.cs | Assertion-free/trivial smoke test fixture. |
| tests/dotnet-experimental/exp-assertion-quality/eval.yaml | Eval scenarios for assertion-quality skill (low-diversity/assertion-free/good-diversity/non-activation). |
| plugins/dotnet-experimental/skills/exp-test-boilerplate-detection/SKILL.md | Skill instructions and reporting format for boilerplate detection. |
| plugins/dotnet-experimental/skills/exp-assertion-quality/SKILL.md | Skill instructions, classification scheme, and metrics dashboard definition. |
Comments suppressed due to low confidence (2)
tests/dotnet-experimental/exp-test-boilerplate-detection/eval.yaml:87
- The non-activation scenario assertion regex includes the bare word
test, which is so broad it can match ordinary prose and won’t reliably confirm that test code was produced. Consider tightening the assertion to require concrete code markers (e.g.,\[TestMethod\],Assert\.) or afile_containsassertion if you expect code to be emitted into a file.
assertions:
- type: "output_matches"
pattern: "(TestMethod|TestClass|\\[Fact\\]|test)"
rubric:
tests/dotnet-experimental/exp-assertion-quality/eval.yaml:114
- The non-activation scenario assertion regex includes the bare word
test, which is likely to match non-code responses and doesn’t reliably assert that a test suite was produced. Tighten this to require concrete MSTest/xUnit/NUnit code markers (e.g.,\[TestMethod\],\[TestClass\],Assert\.) or use file-based assertions if applicable.
assertions:
- type: "output_matches"
pattern: "(TestMethod|TestClass|\\[Fact\\]|test)"
rubric:
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Skill Validation Results
Model: claude-opus-4.6 | Judge: claude-opus-4.6 |
|
/evaluate |
Skill Validation Results
Model: claude-opus-4.6 | Judge: claude-opus-4.6
🔍 Full Results - additional metrics and failure investigation steps |
Two new experimental skills for dotnet-experimental plugin:
exp-test-boilerplate-detection: Detects duplicate boilerplate patterns across .NET test suites and identifies refactoring opportunities. Categories: repeated construction, assertion patterns, copy-paste methods, duplicated setup/teardown, repeated infrastructure.
exp-assertion-quality: Analyzes assertion variety and depth across .NET test suites. Produces metrics dashboard including assertion count, type spread, trivial %, assertion-free tests, and negative assertion coverage.
Both skills include eval.yaml with 3-4 scenarios each (positive, negative, and non-activation) plus test fixtures.