File tree Expand file tree Collapse file tree 1 file changed +22
-0
lines changed Expand file tree Collapse file tree 1 file changed +22
-0
lines changed Original file line number Diff line number Diff line change @@ -559,6 +559,28 @@ 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+
567+ const watcher = watch ( currentDir , ( ev , name ) => {
568+ console . log ( 'CURRENT' , { ev, name} ) ;
569+ } ) ;
570+
571+ await mkdir ( parentPath ) ;
572+
573+ const watcherParent = watch ( parentPath , ( ev , name ) => {
574+ console . log ( 'PARENT' , { ev, name} ) ;
575+ } ) ;
576+
577+ await rmr ( parentPath ) ;
578+ await mkdir ( parentPath ) ;
579+ await mkdir ( subPath ) ;
580+
581+ watcher . close ( ) ;
582+ watcherParent . close ( ) ;
583+ } ) ;
562584 it ( 'should watch removed and re-added directories' , async ( ) => {
563585 const unlinkSpy = createSpy < EmitArgs , void > ( function unlinkSpy ( ) { } ) ;
564586 const addSpy = createSpy < EmitArgs , void > ( function addSpy ( ) { } ) ;
You can’t perform that action at this time.
0 commit comments