Skip to content

Commit 1501ed8

Browse files
committed
chore: fix lint error
1 parent da38055 commit 1501ed8

File tree

2 files changed

+7
-4
lines changed

2 files changed

+7
-4
lines changed

eslint.config.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -225,6 +225,8 @@ export default defineConfig(
225225
},
226226
],
227227

228+
'unicorn/no-useless-undefined': ['error', { checkArguments: false }],
229+
228230
...eslintPluginVitest.configs.recommended.rules,
229231

230232
'vitest/expect-expect': 'off',

test/db.spec.ts

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -53,8 +53,7 @@ describe('db', () => {
5353

5454
await db.query('query');
5555

56-
expect(mocked).toHaveBeenCalledOnce();
57-
expect(mocked).toHaveBeenCalledWith('query', undefined);
56+
expect(mocked).toHaveBeenCalledExactlyOnceWith('query', undefined);
5857
});
5958
});
6059

@@ -90,8 +89,10 @@ describe('db', () => {
9089
it('should call client.query with query', async () => {
9190
await db.query('query');
9291

93-
expect(hoisted.client.query).toHaveBeenCalledOnce();
94-
expect(hoisted.client.query).toHaveBeenCalledWith('query', undefined);
92+
expect(hoisted.client.query).toHaveBeenCalledExactlyOnceWith(
93+
'query',
94+
undefined
95+
);
9596
});
9697

9798
it('should not call client.query if client.connect fails', async () => {

0 commit comments

Comments
 (0)