Explorar el Código

chore: add setupVitest to tsconfig (#8009)

JayFate hace 3 años
padre
commit
10317fa01e
Se han modificado 2 ficheros con 4 adiciones y 3 borrados
  1. 2 2
      scripts/setupVitest.ts
  2. 2 1
      tsconfig.json

+ 2 - 2
scripts/setupVitest.ts

@@ -1,4 +1,4 @@
-import { vi } from 'vitest'
+import { vi, type SpyInstance } from 'vitest'
 
 
 expect.extend({
 expect.extend({
   toHaveBeenWarned(received: string) {
   toHaveBeenWarned(received: string) {
@@ -65,7 +65,7 @@ expect.extend({
   }
   }
 })
 })
 
 
-let warn
+let warn: SpyInstance
 const asserted: Set<string> = new Set()
 const asserted: Set<string> = new Set()
 
 
 beforeEach(() => {
 beforeEach(() => {

+ 2 - 1
tsconfig.json

@@ -33,6 +33,7 @@
     "packages/runtime-dom/types/jsx.d.ts",
     "packages/runtime-dom/types/jsx.d.ts",
     "packages/*/__tests__",
     "packages/*/__tests__",
     "packages/dts-test",
     "packages/dts-test",
-    "packages/vue/jsx-runtime"
+    "packages/vue/jsx-runtime",
+    "scripts/setupVitest.ts"
   ]
   ]
 }
 }