@@ -45,12 +45,6 @@ export interface StartHarperOptions {
4545 * Version of Harper to install and use for this test suite.
4646 */
4747 harperBinPath ?: string ;
48- /**
49- * Runtime environment for Harper ('node' or 'bun').
50- * Set via the HARPER_RUNTIME environment variable ('node' or 'bun').
51- * Defaults to 'node'.
52- */
53- harperRuntime ?: string ;
5448}
5549
5650export interface HarperContext {
@@ -120,7 +114,6 @@ interface RunHarperCommandOptions {
120114 /** When set, stdout and stderr are written to files in this directory */
121115 logDir ?: string ;
122116 harperBinPath ?: string ; // an explicit location installation of a harper package's bin module
123- harperRuntime ?: string ;
124117}
125118
126119/**
@@ -137,16 +130,14 @@ function runHarperCommand({
137130 completionMessage,
138131 logDir,
139132 harperBinPath,
140- harperRuntime,
141133} : RunHarperCommandOptions ) : Promise < ChildProcess > {
142134 const harperScript = getHarperScript ( harperBinPath ) ;
143- harperRuntime ?? = HARPER_RUNTIME ;
135+ const runtime = HARPER_RUNTIME ;
144136 const runtimeArgs =
145- harperRuntime === 'bun'
137+ runtime === 'bun'
146138 ? [ harperScript , ...args ]
147139 : [ '--trace-warnings' , '--force-node-api-uncaught-exceptions-policy=true' , harperScript , ...args ] ;
148- console . log ( 'running' , harperRuntime , runtimeArgs ) ;
149- const proc = spawn ( harperRuntime , runtimeArgs , {
140+ const proc = spawn ( runtime , runtimeArgs , {
150141 env : { ...process . env , ...env } ,
151142 } ) ;
152143
@@ -336,7 +327,6 @@ export async function startHarper(ctx: ContextWithHarper, options?: StartHarperO
336327 env : harperEnv ,
337328 completionMessage : 'successfully started' ,
338329 logDir,
339- harperRuntime : options ?. harperRuntime ,
340330 harperBinPath : options ?. harperBinPath ,
341331 } ) ;
342332
0 commit comments