test(launcher): allow Windows bootstrap integration startup time

Cold and cached launches each have a 15-second command timeout. Give the integration test time for both launches and executable copies instead of the default five-second budget on hosted Windows runners.
This commit is contained in:
sudacode committed 2026-10-01 01:42:10 -07:00
1 parent db45a70ec2
commit 15cb9fe918
1 file changed
+14 -3
@@ -68,7 +68,11 @@ test('preparation failures keep their exit code and never continue to the launch
assert.match(content, /set "ELECTRON_RUN_AS_NODE="/);
});
test('Windows bootstrap prepares once and forwards metacharacter arguments', async (t) => {
// Cold and cached launches each allow 15 seconds, plus executable copies during setup.
test(
'Windows bootstrap prepares once and forwards metacharacter arguments',
{ timeout: 45_000 },
async (t) => {
if (process.platform !== 'win32') return;
const root = workspace(t);
@@ -79,7 +83,13 @@ test('Windows bootstrap prepares once and forwards metacharacter arguments', asy
const localAppData = path.join(root, 'Local App Data');
const bootstrapPath = path.join(root, 'subminer.cmd');
const version = '1.2.3-test';
const cachedBunPath = path.join(localAppData, 'SubMiner', 'launcher-runtime', version, 'bun.exe');
const cachedBunPath = path.join(
localAppData,
'SubMiner',
'launcher-runtime',
version,
'bun.exe',
);
fs.mkdirSync(launcherDirectory, { recursive: true });
fs.copyFileSync(process.execPath, appPath);
fs.writeFileSync(path.join(launcherDirectory, 'version'), version);
@@ -125,4 +135,5 @@ test('Windows bootstrap prepares once and forwards metacharacter arguments', asy
assert.equal(second.exitCode, 0, second.stderr);
const secondPayload: unknown = JSON.parse(second.stdout);
assert.deepEqual(secondPayload, firstPayload);
});
},
);