-
Notifications
You must be signed in to change notification settings - Fork 140
Add more tests for includePanelProcessor.ts
#2704
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add more tests for includePanelProcessor.ts
#2704
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #2704 +/- ##
==========================================
+ Coverage 60.61% 61.36% +0.75%
==========================================
Files 130 130
Lines 7170 7170
Branches 1480 1515 +35
==========================================
+ Hits 4346 4400 +54
+ Misses 2761 2707 -54
Partials 63 63 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR enhances test coverage for includePanelProcessor.ts by adding comprehensive error scenario tests and logger verification. The changes focus on ensuring both the error output and logger calls are properly tested for various edge cases.
Key changes include:
- Addition of logger spy assertions to existing error handling tests
- Addition of 6 new test cases covering missing files, empty src attributes, URL validation, and cyclic references for both
<include>and<popover>elements - Updates to the
expectedErrorsarray to reflect all error messages that will be logged during test execution
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
c048ee5 to
1e2fb8c
Compare
gerteck
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
What is the purpose of this pull request?
Overview of changes:
Adds more tests to
includePanelProcessor.test.ts.Adds assertions to check the errors logged by
loggerusingjest.spyOnAnything you'd like to highlight/discuss:
These changes are derived from the PR #2639
Testing instructions:
Proposed commit message: (wrap lines at 72 characters)
Add more tests for
includePanelProcessor.tsChecklist: ☑️
Reviewer checklist:
Indicate the SEMVER impact of the PR:
At the end of the review, please label the PR with the appropriate label:
r.Major,r.Minor,r.Patch.Breaking change release note preparation (if applicable):