-
-
Notifications
You must be signed in to change notification settings - Fork 813
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
Refactor: jest to vitest of itemDeleteModal : fixes #2557 #2713
Refactor: jest to vitest of itemDeleteModal : fixes #2557 #2713
Conversation
WalkthroughThe pull request focuses on refactoring the Changes
Assessment against linked issues
Possibly related issues
Possibly related PRs
Suggested labels
Suggested reviewers
Poem
📜 Recent review detailsConfiguration used: .coderabbit.yaml 📒 Files selected for processing (1)
🧰 Additional context used📓 Learnings (2)📓 Common learnings
src/screens/OrganizationActionItems/ItemDeleteModal.spec.tsx (2)
🔇 Additional comments (4)src/screens/OrganizationActionItems/ItemDeleteModal.spec.tsx (4)
The addition of
The migration from Jest to Vitest mocking is implemented correctly, maintaining the same toast functionality.
Mock functions correctly updated from
The addition of Let's verify if similar patterns need to be updated in other test files: ✅ Verification successfulLet me analyze the results and generate a final response. All test files properly use The search results show that all test files in the codebase already properly wrap their 🏁 Scripts executedThe following scripts were executed for the analysis: Script: #!/bin/bash
# Search for other test files that might need similar updates
rg -l 'fireEvent\.click' --glob '**/*.{spec,test}.{ts,tsx}' | \
xargs rg -L 'act\(' | \
grep -v 'ItemDeleteModal.spec.tsx'
Length of output: 10327 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
|
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## develop-postgres #2713 +/- ##
====================================================
+ Coverage 86.10% 86.29% +0.19%
====================================================
Files 295 312 +17
Lines 7259 8134 +875
Branches 1591 1785 +194
====================================================
+ Hits 6250 7019 +769
- Misses 781 943 +162
+ Partials 228 172 -56 ☔ View full report in Codecov by Sentry. |
ca0b0f6
into
PalisadoesFoundation:develop-postgres
What kind of change does this PR introduce?
Refactoring
Issue Number:
There are multiple test files in this directory. So it needs multiple PRs to close the issue. This PR fixes one such file inside that directory
itemDeleteModal.spec.tsx
Fixes #2557
Snapshots/Videos:
Summary
Refactored the
ItemDeleteModal.tsx
tests from jest to vitest inItemDeleteModal.spec.tsx
Have you read the contributing guide?
Yes
Summary by CodeRabbit
ItemDeleteModal
tests.itemProps
object to reflect the new mocking approach.