-
-
Notifications
You must be signed in to change notification settings - Fork 758
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
Refactored .\src\utils\useLocalstorage.test.ts from Jest to Vitest #2844
Refactored .\src\utils\useLocalstorage.test.ts from Jest to Vitest #2844
Conversation
WalkthroughThis pull request focuses on refactoring the Changes
Assessment against linked issues
Possibly related issues
Possibly related PRs
Suggested reviewers
Poem
Tip CodeRabbit's docstrings feature is now available as part of our Early Access Program! Simply use the command 📜 Recent review detailsConfiguration used: .coderabbit.yaml 📒 Files selected for processing (1)
🧰 Additional context used📓 Learnings (1)📓 Common learnings
🔇 Additional comments (6)src/utils/useLocalstorage.spec.ts (6)
Would you like me to open an issue to discuss updating the pre-commit hook logic instead of skipping the check?
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 #2844 +/- ##
=====================================================
+ Coverage 68.60% 87.55% +18.94%
=====================================================
Files 296 313 +17
Lines 7358 8204 +846
Branches 1606 1848 +242
=====================================================
+ Hits 5048 7183 +2135
+ Misses 2069 827 -1242
+ Partials 241 194 -47 ☔ View full report in Codecov by Sentry. |
9fbb202
into
PalisadoesFoundation:develop-postgres
What kind of change does this PR introduce?
Refractoring
Issue Number:
Fixes #2755
Did you add tests for your changes?
No
Snapshots/Videos:
Modified the file and ran the test command to check and it was cleared:
Also ensure the linting and formatting:
If relevant, did you update the documentation?
Not yet
Summary
Does this PR introduce a breaking change?
No... it simply converts one test suite framework to other.
Other information
Have checked all the points in the Acceptance Criteria that was asked in the Issue:
3.Ensured all tests in the file pass after migration using npm run test:vitest
4.Maintained the test coverage for the file as 100% after migration as shown in the uploaded snapshot.
5.Upload snapshots for this specific file coverage is 100% in the PR description.
There was one thing I was dealing with that when I made changes in the
src/utils/useLocalstorage.test.ts
file... I got this error due to pre commit hook inscripts/githooks/check-localstorage-usage.js
I read that code and then added the comment
// SKIP_LOCALSTORAGE_CHECK
... the error went away but I am not very sure whether to add this or notHave you read the contributing guide?
Yes
Summary by CodeRabbit
vitest
framework for mocking functions.