@@ -18,8 +18,9 @@ const { buildProject, cleanProject, watchProject } = require("./scripts/build/pr
1818const cmdLineOptions = require ( "./scripts/build/options" ) ;
1919
2020const copyright = "CopyrightNotice.txt" ;
21- const testRoot = "built/local/testRunner/Harness.js" ;
22- //!!! const testRoot = "built/local/run.js";
21+ const testRootFile = "built/local/testRunner/Harness.js" ;
22+ const testRootBundle = "built/local/run.js" ;
23+ const testRoot = testRootBundle ; // use testRootFile to run directly from the module files
2324const cleanTasks = [ ] ;
2425
2526const buildScripts = ( ) => buildProject ( "scripts" ) ;
@@ -322,7 +323,14 @@ task("watch-lssl").flags = {
322323 " --built" : "Compile using the built version of the compiler."
323324} ;
324325
325- const buildTests = ( ) => buildProject ( "src/testRunner" ) ;
326+ const buildTests = series (
327+ ( ) => buildProject ( "src/testRunner" ) ,
328+ ( ) => exec ( "npx" , [
329+ "esbuild" , "--bundle" , "--format=cjs" , "--platform=node" , "--target=node12" ,
330+ "--legal-comments=none" ,
331+ `--outfile=${ testRootBundle } ` , testRootFile ,
332+ ] ) ,
333+ ) ;
326334task ( "tests" , series ( preBuild , parallel ( buildLssl , buildTests ) ) ) ;
327335task ( "tests" ) . description = "Builds the test infrastructure" ;
328336task ( "tests" ) . flags = {
0 commit comments