Skip to content

Commit cc9bab7

Browse files
committed
test: fix test
1 parent dc4f24d commit cc9bab7

File tree

1 file changed

+3
-9
lines changed

1 file changed

+3
-9
lines changed

packages/react-query/src/__tests__/useQuery.types.test.tsx

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -159,18 +159,12 @@ describe('initialData', () => {
159159
describe('structuralSharing', () => {
160160
it('should restrict to same types', () => {
161161
doNotExecute(() => {
162-
const structuralSharing = (
163-
_oldData: number | string | undefined,
164-
newData: number | string,
165-
) => {
166-
return newData
167-
}
168-
169162
useQuery({
170163
queryKey: ['key'],
171164
queryFn: () => 5,
172-
select: String,
173-
structuralSharing,
165+
structuralSharing: (_oldData, newData) => {
166+
return newData
167+
},
174168
})
175169
})
176170
})

0 commit comments

Comments
 (0)