test: harden messaging generator coverage#470
Conversation
Dependency Review✅ No vulnerabilities or license issues or OpenSSF Scorecard issues found.Scanned FilesNone |
There was a problem hiding this comment.
Pull request overview
This PR hardens source-generator test coverage for messaging generators, addressing issue #413 by adding TinyBDD/xUnit scenarios around diagnostics and generation edge cases.
Changes:
- Adds Backplane topology generator tests for missing topology, duplicate defaults, invalid predicates/handlers, blank values, and malformed attributes.
- Adds Splitter/Aggregator generator tests for invalid projections, concrete enumerable projections, aggregator diagnostics, and case-insensitive duplicate policy normalization.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
test/PatternKit.Generators.Tests/BackplaneTopologyGeneratorTests.cs |
Adds diagnostic and malformed-attribute coverage for backplane topology generation. |
test/PatternKit.Generators.Tests/SplitterAggregatorGeneratorTests.cs |
Adds splitter/aggregator diagnostic and successful generation coverage. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| namespace PatternKit.Generators.Messaging; | ||
|
|
||
| [System.AttributeUsage(System.AttributeTargets.Class | System.AttributeTargets.Struct)] | ||
| public sealed class GenerateBackplaneTopologyAttribute : System.Attribute; | ||
|
|
||
| namespace PatternKit.Examples.Messaging; | ||
|
|
||
| [PatternKit.Generators.Messaging.GenerateBackplaneTopology] | ||
| public static partial class OrderBackplane; |
Test Results 12 files 12 suites 11m 25s ⏱️ Results for commit 7e72f23. |
Code Coverage |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #470 +/- ##
==========================================
+ Coverage 97.06% 97.23% +0.16%
==========================================
Files 579 579
Lines 47180 47180
Branches 3086 6768 +3682
==========================================
+ Hits 45797 45874 +77
+ Misses 1383 1306 -77
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
🔍 PR Validation ResultsVersion: `` ✅ Validation Steps
📊 ArtifactsDry-run artifacts have been uploaded and will be available for 7 days. This comment was automatically generated by the PR validation workflow. |
Summary
Refs #413
Verification
BackplaneTopologyGeneratorTests|FullyQualifiedNameSplitterAggregatorGeneratorTests"