test: harden saga generator coverage#477
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
Adds additional TinyBDD scenarios to increase Saga source-generator coverage, focusing on global-namespace struct hosts, sync/async factory naming, completion wiring, and invalid step-shape diagnostics (refs #413).
Changes:
- Added a scenario that validates generation for a global-namespace
structhost with both sync and async steps, including custom factory names and completion wiring in both factories. - Added a scenario that exercises PKSG003 diagnostics for invalid saga-step method shapes (non-static method and missing required parameters).
- Introduced a small helper (
CountOccurrences) to assert repeated emission patterns in generated output.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| var diagnostics = run.Results.SelectMany(result => result.Diagnostics).ToArray(); | ||
| ScenarioExpect.Equal(2, diagnostics.Count(diagnostic => diagnostic.Id == "PKSG003")); | ||
| } |
Code Coverage |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #477 +/- ##
==========================================
+ Coverage 97.27% 97.37% +0.09%
==========================================
Files 579 579
Lines 47188 47188
Branches 3076 6221 +3145
==========================================
+ Hits 45902 45948 +46
+ Misses 1286 1240 -46
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:
|
Test Results 12 files 12 suites 10m 56s ⏱️ Results for commit 89d6018. |
🔍 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