We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent aa6d3f8 commit 6c9e3f3Copy full SHA for 6c9e3f3
packages/react-query/src/__tests__/queryOptions.test.tsx
@@ -0,0 +1,14 @@
1
+import { describe, expect, it } from 'vitest'
2
+import { queryOptions } from '../queryOptions'
3
+import type { UseQueryOptions } from '../types'
4
+
5
+describe('queryOptions', () => {
6
+ it('should return the object received as a parameter without any modification.', () => {
7
+ const object: UseQueryOptions = {
8
+ queryKey: ['key'],
9
+ queryFn: () => Promise.resolve(5),
10
+ } as const
11
12
+ expect(queryOptions(object)).toStrictEqual(object)
13
+ })
14
+})
0 commit comments