(input)
| 112 | } |
| 113 | |
| 114 | function runTestFile(input) { |
| 115 | return new Promise((resolve) => { |
| 116 | const child = spawn(process.execPath, [ |
| 117 | "--experimental-strip-types", |
| 118 | "--test", |
| 119 | "--test-concurrency=1", |
| 120 | input.file, |
| 121 | ], { |
| 122 | cwd: input.repositoryRoot, |
| 123 | env: input.env, |
| 124 | stdio: "inherit", |
| 125 | }); |
| 126 | input.runtime.child = child; |
| 127 | child.once("exit", (code, signal) => { |
| 128 | input.runtime.child = undefined; |
| 129 | if (typeof code === "number") { |
| 130 | resolve(code); |
| 131 | return; |
| 132 | } |
| 133 | resolve(signal ? signalExitCode(signal) : 1); |
| 134 | }); |
| 135 | child.once("error", (error) => { |
| 136 | input.runtime.child = undefined; |
| 137 | console.error(errorMessage(error)); |
| 138 | resolve(1); |
| 139 | }); |
| 140 | }); |
| 141 | } |
| 142 | |
| 143 | function parseArgs(args) { |
| 144 | return { |
no test coverage detected