test: cover activity tracker generator hosts#425
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 nested-host support to ActivityTrackerGenerator (emitting containing partial type wrappers) and rewrites ActivityTrackerGeneratorTests to TinyBDD/xUnit, expanding coverage to defaults, invalid configurations, host shape variants, escaped tracker names, nested accessibility wrappers, and emit success — tracking issue #413.
Changes:
- Emit containing-type partial wrappers (with accessibility/static/abstract/sealed modifiers) around generated activity tracker factories, mirroring
EventStoreGenerator/PipesAndFiltersPipelineGenerator. - Refactor tests to TinyBDD scenarios with a shared
Compile/GeneratorResulthelper that also captures emit success. - Add scenarios for diagnostics (PKAT001/PKAT002), defaults, host shape variants, tracker name escaping, and nested wrapper emission.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| src/PatternKit.Generators/ActivityTracking/ActivityTrackerGenerator.cs | Emits containing partial type wrappers and refactors type-declaration emission into a helper, matching existing nested-host generators. |
| test/PatternKit.Generators.Tests/ActivityTrackerGeneratorTests.cs | Converts to TinyBDD/xUnit, adds defaults/shape/nested/escape/emit-success coverage via a shared compile helper. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Test Results 12 files 12 suites 7m 24s ⏱️ Results for commit 0eb6e68. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #425 +/- ##
==========================================
+ Coverage 90.06% 95.98% +5.92%
==========================================
Files 551 551
Lines 44225 44247 +22
Branches 6364 6367 +3
==========================================
+ Hits 39831 42472 +2641
+ Misses 1914 1775 -139
+ Partials 2480 0 -2480
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. |
Code Coverage |
Summary:
Coverage:
Validation:
Closes part of #413.