File tree 3 files changed +18
-11
lines changed
3 files changed +18
-11
lines changed Load Diff This file was deleted.
Original file line number Diff line number Diff line change
1
+ import { RuleTester } from "eslint" ;
2
+
3
+ interface JestRuleTester extends RuleTester {
4
+ describe : ( text : string , callback : ( ) => void ) => void ;
5
+ it : { title ?: string } & ( ( text : string , callback : ( ) => void ) => void ) ;
6
+ }
7
+
8
+ const ruleTester = RuleTester as unknown as JestRuleTester ;
9
+
10
+ ruleTester . describe = ( text : string , callback : ( ) => void ) => {
11
+ ruleTester . it . title = text ;
12
+ return callback . call ( this ) ;
13
+ } ;
14
+
15
+ ruleTester . it = ( text : string , callback : ( ) => void ) => {
16
+ test ( `${ ruleTester . it . title } : ${ text } ` , callback ) ;
17
+ } ;
Original file line number Diff line number Diff line change 69
69
"jest" : {
70
70
"preset" : " ts-jest" ,
71
71
"setupFilesAfterEnv" : [
72
- " ./jest.setup.js "
72
+ " ./jest.setup.ts "
73
73
],
74
74
"testRegex" : " .test.ts$"
75
75
},
You can’t perform that action at this time.
0 commit comments