Skip to content

Commit c1cbb74

Browse files
committed
chore: fix types
1 parent 45984d5 commit c1cbb74

File tree

3 files changed

+7
-5
lines changed

3 files changed

+7
-5
lines changed

packages/compiler-core/__tests__/parse.spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3026,7 +3026,7 @@ foo
30263026
]
30273027
}
30283028

3029-
for (const key of Object.keys(patterns) as (keyof typeof patterns)[]) {
3029+
for (const key of Object.keys(patterns)) {
30303030
describe(key, () => {
30313031
for (const { code, errors, options } of patterns[key]) {
30323032
test(

packages/runtime-core/__tests__/apiAsyncComponent.spec.ts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -325,7 +325,8 @@ describe('api: defineAsyncComponent', () => {
325325
render: () => h(Foo)
326326
})
327327

328-
const handler = (app.config.errorHandler = vi.fn())
328+
const handler = vi.fn()
329+
app.config.errorHandler = handler
329330

330331
app.mount(root)
331332
expect(serializeInner(root)).toBe('<!---->')
@@ -422,7 +423,8 @@ describe('api: defineAsyncComponent', () => {
422423
const app = createApp({
423424
render: () => h(Foo)
424425
})
425-
const handler = (app.config.errorHandler = vi.fn())
426+
const handler = vi.fn()
427+
app.config.errorHandler = handler
426428
app.mount(root)
427429
expect(serializeInner(root)).toBe('<!---->')
428430
await timeout(1)

packages/runtime-dom/__tests__/customizedBuiltIn.spec.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
import { vi } from 'vitest'
1+
import { vi, SpyInstance } from 'vitest'
22
import { render, h } from '@vue/runtime-dom'
33

44
describe('customized built-in elements support', () => {
5-
let createElement: vi.SpyInstance
5+
let createElement: SpyInstance
66
afterEach(() => {
77
createElement.mockRestore()
88
})

0 commit comments

Comments
 (0)