Open History to see the last commit
1import { describe, expect, it } from 'vitest'
2import { queryKey } from '@tanstack/query-test-utils'
3β
4import { infiniteQueryOptions } from '../infiniteQueryOptions'
5import type { UseInfiniteQueryOptions } from '../types'
6β
7describe('infiniteQueryOptions', () => {
8 it('should return the object received as a parameter without any modification.', () => {
9 const object: UseInfiniteQueryOptions = {
10 queryKey: queryKey(),
11 queryFn: () => Promise.resolve(5),
12 getNextPageParam: () => null,
13 initialPageParam: null,
14 }
15β
16 expect(infiniteQueryOptions(object)).toBe(object)
17 })
18})