@@ -28,19 +28,27 @@ const objectTable = [
2828// test.each
2929
3030expectType < void > (
31- test . each ( list ) ( 'some test' , a => {
31+ test . each ( list ) ( 'some test' , ( a , done ) => {
3232 expectType < number > ( a ) ;
33+
34+ expectType < ( reason ?: string | Error ) => void > ( done ) ;
3335 } ) ,
3436) ;
3537expectType < void > (
36- test . each ( list ) ( 'some test' , a => {
37- expectType < number > ( a ) ;
38- } ) ,
38+ test . each ( list ) (
39+ 'some test' ,
40+ a => {
41+ expectType < number > ( a ) ;
42+ } ,
43+ 1000 ,
44+ ) ,
3945) ;
4046
4147expectType < void > (
42- test . each ( tupleList ) ( 'some test' , b => {
48+ test . each ( tupleList ) ( 'some test' , ( b , done ) => {
4349 expectType < 'one' | 'two' | 'three' > ( b ) ;
50+
51+ expectType < ( reason ?: string | Error ) => void > ( done ) ;
4452 } ) ,
4553) ;
4654expectType < void > (
@@ -54,8 +62,10 @@ expectType<void>(
5462) ;
5563
5664expectType < void > (
57- test . each ( [ 3 , 4 , 'seven' ] ) ( 'some test' , c => {
65+ test . each ( [ 3 , 4 , 'seven' ] ) ( 'some test' , ( c , done ) => {
5866 expectType < string | number > ( c ) ;
67+
68+ expectType < ( reason ?: string | Error ) => void > ( done ) ;
5969 } ) ,
6070) ;
6171expectType < void > (
@@ -134,11 +144,13 @@ expectType<void>(
134144) ;
135145
136146expectType < void > (
137- test . each ( objectTable ) ( 'some test' , ( { a, b, expected, extra} ) => {
147+ test . each ( objectTable ) ( 'some test' , ( { a, b, expected, extra} , done ) => {
138148 expectType < number > ( a ) ;
139149 expectType < number > ( b ) ;
140150 expectType < string > ( expected ) ;
141151 expectType < boolean | undefined > ( extra ) ;
152+
153+ expectType < ( reason ?: string | Error ) => void > ( done ) ;
142154 } ) ,
143155) ;
144156expectType < void > (
@@ -148,11 +160,13 @@ expectType<void>(
148160 { a : 5 , b : 6 , expected : 'eleven' } ,
149161 ] ) (
150162 'some test' ,
151- ( { a, b, expected, extra} ) => {
163+ ( { a, b, expected, extra} , done ) => {
152164 expectType < number > ( a ) ;
153165 expectType < number > ( b ) ;
154166 expectType < string > ( expected ) ;
155167 expectType < boolean | undefined > ( extra ) ;
168+
169+ expectType < ( reason ?: string | Error ) => void > ( done ) ;
156170 } ,
157171 1000 ,
158172 ) ,
@@ -164,10 +178,12 @@ expectType<void>(
164178 ${ 1 } | ${ 1 } | ${ 2 }
165179 ${ 1 } | ${ 2 } | ${ 3 }
166180 ${ 2 } | ${ 1 } | ${ 3 }
167- ` ( 'some test' , ( { a, b, expected} ) => {
181+ ` ( 'some test' , ( { a, b, expected} , done ) => {
168182 expectType < number > ( a ) ;
169183 expectType < number > ( b ) ;
170184 expectType < number > ( expected ) ;
185+
186+ expectType < ( reason ?: string | Error ) => void > ( done ) ;
171187 } ) ,
172188) ;
173189expectType < void > (
@@ -185,9 +201,11 @@ expectType<void>(
185201 item | expected
186202 ${ 'a' } | ${ true }
187203 ${ 'b' } | ${ false }
188- ` ( 'some test' , ( { item, expected} ) => {
204+ ` ( 'some test' , ( { item, expected} , done ) => {
189205 expectType < string > ( item ) ;
190206 expectType < boolean > ( expected ) ;
207+
208+ expectType < ( reason ?: string | Error ) => void > ( done ) ;
191209 } ) ,
192210) ;
193211expectType < void > (
0 commit comments