-
-
Notifications
You must be signed in to change notification settings - Fork 869
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
Improve Code Coverage in src\components\RecurrenceOptions\CustomRecurrenceModal.tsx #3510
Improve Code Coverage in src\components\RecurrenceOptions\CustomRecurrenceModal.tsx #3510
Conversation
WalkthroughThe pull request introduces a new test case in the Changes
Assessment against linked issues
Possibly related issues
Suggested reviewers
Poem
📜 Recent review detailsConfiguration used: .coderabbit.yaml 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
⏰ Context from checks skipped due to timeout of 90000ms (2)
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
Documentation and Community
|
Our Pull Request Approval ProcessThanks for contributing! Testing Your CodeRemember, your PRs won't be reviewed until these criteria are met:
Our policies make our code better. ReviewersDo not assign reviewers. Our Queue Monitors will review your PR and assign them.
Reviewing Your CodeYour reviewer(s) will have the following roles:
CONTRIBUTING.mdRead our CONTRIBUTING.md file. Most importantly:
Other
|
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.
Actionable comments posted: 0
🔭 Outside diff range comments (1)
src/components/RecurrenceOptions/CustomRecurrenceModal.tsx (1)
Line range hint
380-380
: Remove the istanbul ignore next comment.The pipeline failure indicates presence of a code coverage disable statement. The
/* istanbul ignore next */
comment at line 380 should be removed as the new test case inCustomRecurrence.spec.tsx
now covers this code path.🧰 Tools
🪛 GitHub Actions: PR Workflow
[error] File contains code coverage disable statement. Please remove it and add the appropriate tests.
🧹 Nitpick comments (1)
src/components/RecurrenceOptions/CustomRecurrence.spec.tsx (1)
388-388
: Improve test description for clarity.The test description could be more specific about what behavior it's testing. Consider renaming it to something like: "Should handle null/invalid end date values without changing state".
📜 Review details
Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (2)
src/components/RecurrenceOptions/CustomRecurrence.spec.tsx
(1 hunks)src/components/RecurrenceOptions/CustomRecurrenceModal.tsx
(1 hunks)
🧰 Additional context used
🪛 GitHub Actions: PR Workflow
src/components/RecurrenceOptions/CustomRecurrenceModal.tsx
[error] File contains code coverage disable statement. Please remove it and add the appropriate tests.
🔇 Additional comments (1)
src/components/RecurrenceOptions/CustomRecurrenceModal.tsx (1)
135-135
: LGTM! Safe to remove the nullish coalescing operator.The removal of
??
is safe asweekDays
will always be defined at this point due to the condition check at line 134.🧰 Tools
🪛 GitHub Actions: PR Workflow
[error] File contains code coverage disable statement. Please remove it and add the appropriate tests.
Please fix the failing tests |
Working on it. |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## develop-postgres #3510 +/- ##
=====================================================
+ Coverage 1.90% 88.64% +86.74%
=====================================================
Files 316 341 +25
Lines 8249 8625 +376
Branches 1880 1924 +44
=====================================================
+ Hits 157 7646 +7489
+ Misses 8083 637 -7446
- Partials 9 342 +333 ☔ View full report in Codecov by Sentry. |
@palisadoes Please review changes LGTM. |
f2e1077
into
PalisadoesFoundation:develop-postgres
thankyou @palisadoes |
What kind of change does this PR introduce?
Improve Code Coverage in src\components\RecurrenceOptions\CustomRecurrenceModal.tsx
Issue Number:
Fixes #3057
Snapshots/Videos:
If relevant, did you update the documentation?
No
Summary
Does this PR introduce a breaking change?
No
Checklist
CodeRabbit AI Review
Test Coverage
Other information
Have you read the contributing guide?
Summary by CodeRabbit
Tests
Refactor
handleDayClick
function inCustomRecurrenceModal
by removing the nullish coalescing operator when updatingweekDays
.onChange
handler for theDatePicker
component.