diff --git a/packages/angular-query-experimental/src/__tests__/inject-is-mutating.test.ts b/packages/angular-query-experimental/src/__tests__/inject-is-mutating.test.ts index 08b69616607..ccfa8e46407 100644 --- a/packages/angular-query-experimental/src/__tests__/inject-is-mutating.test.ts +++ b/packages/angular-query-experimental/src/__tests__/inject-is-mutating.test.ts @@ -31,7 +31,7 @@ describe('injectIsMutating', () => { vi.useRealTimers() }) - test('should properly return isMutating state', async () => { + test('should properly return isMutating state', () => { TestBed.runInInjectionContext(() => { const isMutating = injectIsMutating() const mutation = injectMutation(() => ({ diff --git a/packages/angular-query-experimental/src/__tests__/inject-mutation.test.ts b/packages/angular-query-experimental/src/__tests__/inject-mutation.test.ts index b61b4e25b0e..a15daa54db3 100644 --- a/packages/angular-query-experimental/src/__tests__/inject-mutation.test.ts +++ b/packages/angular-query-experimental/src/__tests__/inject-mutation.test.ts @@ -120,7 +120,7 @@ describe('injectMutation', () => { }) }) - test('reactive options should update mutation', async () => { + test('reactive options should update mutation', () => { const mutationCache = queryClient.getMutationCache() // Signal will be updated before the mutation is called // this test confirms that the mutation uses the updated value diff --git a/packages/angular-query-experimental/src/__tests__/inject-query.test.ts b/packages/angular-query-experimental/src/__tests__/inject-query.test.ts index 849a7ef42e0..51d20efaced 100644 --- a/packages/angular-query-experimental/src/__tests__/inject-query.test.ts +++ b/packages/angular-query-experimental/src/__tests__/inject-query.test.ts @@ -232,7 +232,7 @@ describe('injectQuery', () => { ...options, })) const fromWrappedQuery = TestBed.runInInjectionContext(() => - createWrappedQuery([''], async () => '1'), + createWrappedQuery([''], () => Promise.resolve('1')), ) expectTypeOf(fromWrappedQuery.data()).toEqualTypeOf() @@ -252,7 +252,7 @@ describe('injectQuery', () => { >, ) => injectQuery(() => ({ queryKey: qk, queryFn: fetcher, ...options })) const fromWrappedFuncStyleQuery = TestBed.runInInjectionContext(() => - createWrappedFuncStyleQuery([''], async () => true), + createWrappedFuncStyleQuery([''], () => Promise.resolve(true)), ) expectTypeOf(fromWrappedFuncStyleQuery.data()).toEqualTypeOf< boolean | undefined diff --git a/packages/query-devtools/src/__tests__/utils.test.ts b/packages/query-devtools/src/__tests__/utils.test.ts index e57933cd2df..60fbcf130ec 100644 --- a/packages/query-devtools/src/__tests__/utils.test.ts +++ b/packages/query-devtools/src/__tests__/utils.test.ts @@ -4,7 +4,7 @@ import { deleteNestedDataByPath, updateNestedDataByPath } from '../utils' describe('Utils tests', () => { describe('updatedNestedDataByPath', () => { describe('array', () => { - it('should update data correctly', async () => { + it('should update data correctly', () => { const oldData = ['one', 'two', 'three'] const newData = updateNestedDataByPath(oldData, ['1'], 'new') @@ -29,7 +29,7 @@ describe('Utils tests', () => { }) describe('object', () => { - it('should update data correctly', async () => { + it('should update data correctly', () => { const oldData = { title: 'Hello world', id: 1, createdAt: '2021-01-01' } const newData = updateNestedDataByPath( @@ -58,7 +58,7 @@ describe('Utils tests', () => { }) describe('set', () => { - it('should update data correctly', async () => { + it('should update data correctly', () => { const oldData = new Set([123, 321, 'hello', 'world']) const newData = updateNestedDataByPath(oldData, ['2'], 'hi') @@ -85,7 +85,7 @@ describe('Utils tests', () => { }) describe('map', () => { - it('should update data correctly', async () => { + it('should update data correctly', () => { const oldData = new Map([ ['en', 'hello'], ['fr', 'bonjour'], @@ -113,7 +113,7 @@ describe('Utils tests', () => { }) describe('nested data', () => { - it('should update data correctly', async () => { + it('should update data correctly', () => { /* eslint-disable cspell/spellchecker */ const oldData = new Map([ [ @@ -377,7 +377,7 @@ describe('Utils tests', () => { }) describe('deleteNestedDataByPath', () => { - it('should delete item from array correctly', async () => { + it('should delete item from array correctly', () => { const oldData = ['one', 'two', 'three'] const newData = deleteNestedDataByPath(oldData, ['1']) @@ -399,7 +399,7 @@ describe('Utils tests', () => { `) }) - it('should delete item from object correctly', async () => { + it('should delete item from object correctly', () => { const oldData = { title: 'Hello world', id: 1, createdAt: '2021-01-01' } const newData = deleteNestedDataByPath(oldData, ['createdAt']) @@ -472,7 +472,7 @@ describe('Utils tests', () => { }) describe('nested data', () => { - it('should delete nested items correctly', async () => { + it('should delete nested items correctly', () => { /* eslint-disable cspell/spellchecker */ const oldData = new Map([ [ diff --git a/packages/query-persist-client-core/src/__tests__/utils.ts b/packages/query-persist-client-core/src/__tests__/utils.ts index d633cf72681..01287a2422d 100644 --- a/packages/query-persist-client-core/src/__tests__/utils.ts +++ b/packages/query-persist-client-core/src/__tests__/utils.ts @@ -17,7 +17,7 @@ export function createMockPersister(): Persister { let storedState: PersistedClient | undefined return { - async persistClient(persistClient: PersistedClient) { + persistClient(persistClient: PersistedClient) { storedState = persistClient }, async restoreClient() {