@@ -5,7 +5,7 @@ import { delay } from '../promise/delay';
55describe ( 'forEachAsync' , ( ) => {
66 it ( 'executes callback for each element asynchronously' , async ( ) => {
77 const arr = [ 1 , 2 , 3 ] ;
8- const callback = vi . fn ( async ( n : number ) => {
8+ const callback = vi . fn ( async ( ) => {
99 await delay ( 10 ) ;
1010 } ) ;
1111
@@ -19,7 +19,7 @@ describe('forEachAsync', () => {
1919
2020 it ( 'handles empty array' , async ( ) => {
2121 const arr : number [ ] = [ ] ;
22- const callback = vi . fn ( async ( n : number ) => { } ) ;
22+ const callback = vi . fn ( async ( ) => { } ) ;
2323
2424 await forEachAsync ( arr , callback ) ;
2525 expect ( callback ) . toHaveBeenCalledTimes ( 0 ) ;
@@ -41,7 +41,7 @@ describe('forEachAsync', () => {
4141 let running = 0 ;
4242 let maxRunning = 0 ;
4343
44- const fn = vi . fn ( async ( item : number ) => {
44+ const fn = vi . fn ( async ( ) => {
4545 running ++ ;
4646
4747 if ( running > maxRunning ) {
@@ -65,7 +65,7 @@ describe('forEachAsync', () => {
6565 let running = 0 ;
6666 let maxRunning = 0 ;
6767
68- const fn = async ( item : number ) => {
68+ const fn = async ( ) => {
6969 running ++ ;
7070 if ( running > maxRunning ) {
7171 maxRunning = running ;
0 commit comments