@@ -6,16 +6,24 @@ import { parse as parseYaml } from "yaml";
66import { spawn } from "child_process" ;
77import fsExtra from "fs-extra" ;
88
9- const { readFileSync, mkdirp, readJSON, writeJSON, rmdir } = fsExtra ;
9+ const { readFileSync, mkdirp, readJSON, writeJSON, rmSync } = fsExtra ;
1010const __dirname = dirname ( fileURLToPath ( import . meta. url ) ) ;
1111
1212const starterTemplateDir = "../../../starters/angular/basic" ;
1313
1414const errors : any [ ] = [ ] ;
15-
16- await rmdir ( join ( __dirname , "runs" ) , { recursive : true } ) . catch ( ( ) => undefined ) ;
17-
18- console . log ( "\nBuilding and starting test projects in parallel..." ) ;
15+ console . log ( "About to remove runs directory (sync)" ) ;
16+ try {
17+ rmSync ( join ( __dirname , "runs" ) , { recursive : true } ) ;
18+ console . log ( "Runs directory removed successfully (sync)" ) ;
19+ } catch ( err ) {
20+ console . error ( "Error removing runs directory (sync):" , err ) ;
21+ // console.error("Error details:", err.message, err.stack);
22+ // if (err.code) {
23+ // console.error("Error code:", err.code); // Check error codes
24+ // }
25+ }
26+ console . log ( "Finished removal attempt" ) ;
1927
2028const tests = await Promise . all (
2129 [
@@ -41,7 +49,13 @@ const tests = await Promise.all(
4149 stdio : "inherit" ,
4250 shell : true ,
4351 } ) ;
44-
52+ console . log ( `[${ runId } ] updating angular to next tag` ) ;
53+ console . log ( `[${ runId } ] > ng update @angular/cli@next @angular/core@next` ) ;
54+ await promiseSpawn ( "ng" , [ "update" , "@angular/cli@next" , "@angular/core@next" ] , {
55+ cwd,
56+ stdio : "inherit" ,
57+ shell : true ,
58+ } ) ;
4559 const angularJSON = JSON . parse ( ( await readFile ( join ( cwd , "angular.json" ) ) ) . toString ( ) ) ;
4660
4761 if ( ! enableSSR ) {
0 commit comments