Skip to content

Commit

Permalink
test: update tests, use matched types for mutate api (#2781)
Browse files Browse the repository at this point in the history
  • Loading branch information
huozhi committed Sep 12, 2023
1 parent ed0453a commit c3133d0
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions test/type/mutate.ts
Original file line number Diff line number Diff line change
Expand Up @@ -61,12 +61,12 @@ export function useMutatorTypes() {
const { mutate } = useSWR<string>('')

mutate(async () => '1')
mutate(async () => '1', { populateCache: false })

// @ts-expect-error
mutate(async () => 1)

// FIXME: this should work.
// mutate(async () => 1, { populateCache: false })
// @ts-expect-error
mutate(async () => 1, { populateCache: false })
}

export function useConfigMutate() {
Expand Down

0 comments on commit c3133d0

Please sign in to comment.