File tree Expand file tree Collapse file tree 1 file changed +17
-0
lines changed Expand file tree Collapse file tree 1 file changed +17
-0
lines changed Original file line number Diff line number Diff line change @@ -559,6 +559,23 @@ const runTests = (baseopts: chokidar.ChokidarOptions) => {
559559 ok ( spy . calls [ 0 ] [ 1 ] ) ; // stats
560560 ok ( rawSpy . called ) ;
561561 } ) ;
562+ it ( 'blergh' , async ( ) => {
563+ const parentPath = dpath ( 'subdir2' ) ;
564+ const subPath = dpath ( 'subdir2/subsub' ) ;
565+ const { watch} = await import ( 'fs' ) ;
566+ const watcherFn = ( curr : unknown , prev : unknown ) => {
567+ console . log ( { curr, prev} ) ;
568+ } ;
569+
570+ const watcher = watch ( currentDir , { recursive : true } , watcherFn ) ;
571+
572+ await mkdir ( parentPath ) ;
573+ await rmr ( parentPath ) ;
574+ await mkdir ( parentPath ) ;
575+ await mkdir ( subPath ) ;
576+
577+ watcher . close ( ) ;
578+ } ) ;
562579 it ( 'should watch removed and re-added directories' , async ( ) => {
563580 const unlinkSpy = createSpy < EmitArgs , void > ( function unlinkSpy ( ) { } ) ;
564581 const addSpy = createSpy < EmitArgs , void > ( function addSpy ( ) { } ) ;
You can’t perform that action at this time.
0 commit comments