Skip to content

Commit

Permalink
fix TS warnings in tests
Browse files Browse the repository at this point in the history
  • Loading branch information
dai-shi committed Jul 31, 2023
1 parent 657fd50 commit 89a9527
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
8 changes: 4 additions & 4 deletions tests/react/utils/useAtomCallback.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ it('useAtomCallback with get', async () => {
}, [])
)
useEffect(() => {
const timer = setInterval(async () => {
await readCount()
const timer = setInterval(() => {
readCount()
}, 10)
return () => {
clearInterval(timer)
Expand Down Expand Up @@ -80,8 +80,8 @@ it('useAtomCallback with set and update', async () => {
}, [])
)
useEffect(() => {
const timer = setInterval(async () => {
await changeCount()
const timer = setInterval(() => {
changeCount()
}, 10)
return () => {
clearInterval(timer)
Expand Down
2 changes: 1 addition & 1 deletion tests/vanilla/dependency.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ it('correctly updates async derived atom after get/set update', async () => {
const baseAtom = atom(0)
const derivedAsyncAtom = atom(
async (get) => get(baseAtom) + 1,
async (get, set, val) => set(baseAtom, val as number)
async (_get, set, val) => set(baseAtom, val as number)
)

const store = createStore()
Expand Down

0 comments on commit 89a9527

Please sign in to comment.