test(svelte-query/createMutation): add test for recreating observer when 'queryClient' changes#10244
Conversation
…hen 'queryClient' changes
|
|
View your CI Pipeline Execution ↗ for commit a1a1c30
☁️ Nx Cloud last updated this comment at |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
📝 WalkthroughWalkthroughA new test case is added to verify that mutations properly recreate their observer when the underlying QueryClient dependency changes, validating reactive behavior across client swaps. Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Poem
🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
🎯 Changes
Add a test for
createMutationto verify that theMutationObserveris recreated when the providedqueryClientchanges at runtime.This covers
createMutation.svelte.tslines 41 and 61 (watchChangescallbacks for client/observer changes), improving line coverage from 89.47% to 100%.✅ Checklist
pnpm run test:pr.🚀 Release Impact
Summary by CodeRabbit