-
-
Notifications
You must be signed in to change notification settings - Fork 3.4k
test(react-query/useSuspenseQuery): use precise time in 'advanceTimersByTimeAsync', and add 'expect' using 'toBeInTheDocument' #9455
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
Conversation
…sByTimeAsync', and add 'expect' using 'toBeInTheDocument'
…e-time-advanceTimersByTimeAsync
View your CI Pipeline Execution ↗ for commit d0be879
☁️ Nx Cloud last updated this comment at |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #9455 +/- ##
===========================================
+ Coverage 45.30% 84.38% +39.07%
===========================================
Files 208 26 -182
Lines 8283 365 -7918
Branches 1863 108 -1755
===========================================
- Hits 3753 308 -3445
+ Misses 4085 48 -4037
+ Partials 445 9 -436 🚀 New features to boost your workflow:
|
…e-time-advanceTimersByTimeAsync
@@ -69,12 +69,12 @@ describe('useSuspenseQuery', () => { | |||
</React.Suspense>, | |||
) | |||
|
|||
await act(() => vi.advanceTimersByTimeAsync(11)) | |||
rendered.getByText('data: 1') | |||
await act(() => vi.advanceTimersByTimeAsync(10)) |
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.
tight 👍
No description provided.