@@ -202,13 +202,16 @@ it.layer(layerTest, { excludeTestServices: true })("WorkspaceEntries", (it) => {
202202 const fileSystem = yield * FileSystem . FileSystem ;
203203 const path = yield * Path . Path ;
204204 // Shaped like a pnpm `node_modules`: one link per package into `.pnpm`.
205+ const directoryPath = [ ...Array . from ( { length : 80 } , ( ) => "nested" ) , "node_modules" ] . join (
206+ "/" ,
207+ ) ;
205208 const packages = Array . from ( { length : 200 } , ( _ , index ) => `pkg-${ index } ` ) ;
206209 yield * Effect . forEach (
207210 packages ,
208211 ( name ) =>
209212 Effect . gen ( function * ( ) {
210- yield * writeTextFile ( cwd , `node_modules /.pnpm/${ name } /index.js` ) ;
211- yield * fileSystem . symlink ( `.pnpm/${ name } ` , path . join ( cwd , "node_modules" , name ) ) ;
213+ yield * writeTextFile ( cwd , `${ directoryPath } /.pnpm/${ name } /index.js` ) ;
214+ yield * fileSystem . symlink ( `.pnpm/${ name } ` , path . join ( cwd , directoryPath , name ) ) ;
212215 } ) ,
213216 { concurrency : 32 , discard : true } ,
214217 ) ;
@@ -225,9 +228,12 @@ it.layer(layerTest, { excludeTestServices: true })("WorkspaceEntries", (it) => {
225228 } ) as typeof NodeFSP . realpath ) ;
226229
227230 const workspaceEntries = yield * WorkspaceEntries . WorkspaceEntries ;
228- const { entries } = yield * workspaceEntries . list ( { cwd, directoryPath : "node_modules" } ) ;
231+ const { entries } = yield * workspaceEntries . list ( { cwd, directoryPath } ) ;
229232 expect ( entries . map ( ( entry ) => entry . path ) . toSorted ( ) ) . toEqual (
230- [ "node_modules/.pnpm" , ...packages . map ( ( name ) => `node_modules/${ name } ` ) ] . toSorted ( ) ,
233+ [
234+ `${ directoryPath } /.pnpm` ,
235+ ...packages . map ( ( name ) => `${ directoryPath } /${ name } ` ) ,
236+ ] . toSorted ( ) ,
231237 ) ;
232238 expect ( entries . every ( ( entry ) => entry . kind === "directory" ) ) . toBe ( true ) ;
233239 expect ( maxInFlight ) . toBeLessThanOrEqual ( 64 ) ;
0 commit comments