Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
54 commits
Select commit Hold shift + click to select a range
946f980
Strip renderer-only report paths from shared utils.
jtklein-agents Nov 13, 2026
fa627f8
Type shared UserFixError as TypeScript (#74).
jtklein-agents Nov 13, 2026
dd1d6f8
Extract run, model selection, and ASTRAL handlers from api.
jtklein-agents Nov 13, 2026
8e233f0
Convert main helpers without ipc to TypeScript (#75).
jtklein-agents Nov 13, 2026
59cfe91
Type catch bindings and keep helper types module-local.
jtklein-agents Nov 13, 2026
ea8dcd2
Merge pull request #87 from jtklein-agents/ticket/71-strip-renderer-u…
jtklein-agents Nov 14, 2026
9843da6
Rename ipc channel catalogue to TypeScript.
jtklein-agents Nov 14, 2026
a2f4883
Type ipc channel exports as string literals.
jtklein-agents Nov 14, 2026
01c62ca
Prefer as const for ipc channel string literals.
jtklein-agents Nov 14, 2026
9008f7b
Fail typecheck baseline on unused src/ lines.
jtklein-agents Nov 14, 2026
87ee016
Lint typed catch and export boundaries on main TypeScript.
jtklein-agents Nov 14, 2026
b12692b
Merge pull request #88 from jtklein-agents/73-typed-ipc-catalogue
jtklein-agents Nov 14, 2026
b43c4d0
Merge pull request #89 from jtklein-agents/74-typed-shared-errors
jtklein-agents Nov 14, 2026
175132f
Merge pull request #91 from jtklein-agents/ticket/75-typescript-main-…
jtklein-agents Nov 14, 2026
37b1a88
Merge pull request #90 from jtklein-agents/72-extract-run-handlers
jtklein-agents Nov 14, 2026
7ad8580
Merge branch 'spec/67-main-typescript' into retro-unused-baseline
jtklein-agents Nov 14, 2026
1cea6ac
Merge pull request #92 from jtklein-agents/retro-unused-baseline
jtklein-agents Nov 14, 2026
4102ff9
Rename shared utils to TypeScript.
jtklein-agents Nov 14, 2026
c4e5b96
Type shared io as TypeScript (#76).
jtklein-agents Nov 14, 2026
9d0da48
Type shared utils exports and clear their baseline.
jtklein-agents Nov 14, 2026
9a5f74c
Convert main dialogs and state report to TypeScript (#78).
jtklein-agents Nov 14, 2026
364f7b2
Enforce typed exports on shared common TypeScript.
jtklein-agents Nov 14, 2026
6473b64
Lint ban instanceof Error in main catch clauses.
jtklein-agents Nov 14, 2026
7b7d052
Merge pull request #94 from jtklein-agents/ticket/76-typed-shared-io
jtklein-agents Nov 14, 2026
fa0f4fc
Merge pull request #93 from jtklein-agents/77-typed-shared-utils
jtklein-agents Nov 14, 2026
416f6c9
Merge pull request #95 from jtklein-agents/ticket-78-ts-main-dialogs
jtklein-agents Nov 14, 2026
1b5471d
Convert main menu modules to TypeScript (#83).
jtklein-agents Nov 14, 2026
8dd626d
Drop instanceof Error in shared io catch.
jtklein-agents Nov 14, 2026
5b286c2
Merge pull request #96 from jtklein-agents/83-typescript-menu
jtklein-agents Nov 14, 2026
9ea6e2c
Rename shared process helpers to TypeScript.
jtklein-agents Nov 14, 2026
b769633
Type shared process helpers and clear their baseline.
jtklein-agents Nov 14, 2026
197502e
Merge pull request #97 from jtklein-agents/79-typescript-shared-proce…
jtklein-agents Nov 14, 2026
c15670d
Type the model-selection module and clear its baseline.
jtklein-agents Nov 14, 2026
f6c4601
Rename ASTRAL module to TypeScript.
jtklein-agents Nov 14, 2026
f843d43
Type the ASTRAL module and clear its baseline.
jtklein-agents Nov 14, 2026
bfeed43
Rename start-run module to TypeScript.
jtklein-agents Nov 14, 2026
54f9f04
Type the start-run module and clear its baseline.
jtklein-agents Nov 14, 2026
536d3a0
Bind typecheck baseline continuations to their src/ owner.
jtklein-agents Nov 14, 2026
adbc51c
Type run id as number to match RunList.
jtklein-agents Nov 14, 2026
f363ccf
Merge pull request #99 from jtklein-agents/81-typescript-model-select…
jtklein-agents Nov 14, 2026
0f3cb70
Merge spec/67-main-typescript into 82-typescript-astral-module.
jtklein-agents Nov 14, 2026
c2e677c
Merge pull request #100 from jtklein-agents/82-typescript-astral-module
jtklein-agents Nov 14, 2026
c051a2f
Merge spec/67-main-typescript; tighten run and alignment ids.
jtklein-agents Nov 14, 2026
a312bde
Merge pull request #98 from jtklein-agents/80-typescript-start-run-mo…
jtklein-agents Nov 14, 2026
cf4f4ee
Rename thin api module to TypeScript.
jtklein-agents Nov 14, 2026
d6305b3
Type the thin api module and clear its baseline.
jtklein-agents Nov 14, 2026
89e3e6e
Tighten api handler argument types to match the page.
jtklein-agents Nov 14, 2026
07a1493
Merge pull request #101 from jtklein-agents/84-typescript-thin-api-an…
jtklein-agents Nov 14, 2026
30c75bd
Rename main entry to TypeScript.
jtklein-agents Nov 14, 2026
ea4a371
Type the main entry and clear its icon diagnostic.
jtklein-agents Nov 14, 2026
6795e1f
Alias yarn test to the Jest suite.
jtklein-agents Nov 14, 2026
238e5d4
Merge pull request #102 from jtklein-agents/85-typescript-main-entry
jtklein-agents Nov 14, 2026
4116368
Remove the main-process TypeScript note from TODO.
jtklein-agents Nov 14, 2026
440fb6c
Merge pull request #103 from jtklein-agents/impl-86
jtklein-agents Nov 14, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 20 additions & 0 deletions .eslintrc.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -68,5 +68,25 @@ module.exports = {
],
},
},
{
// Main TypeScript (#67): full typing under non-strict — typed catch, typed exports.
files: ['src/main/**/*.{ts,tsx}', 'src/common/**/*.{ts,tsx}'],
rules: {
'@typescript-eslint/explicit-module-boundary-types': 'error',
'no-restricted-syntax': [
'error',
{
selector: 'CatchClause[param][param.typeAnnotation=undefined]',
message: 'Annotate catch bindings (use unknown).',
},
{
selector:
'CatchClause BinaryExpression[operator="instanceof"][right.name="Error"]',
message:
'Read (error as Error).message; jsdom Error is a different realm from Node throws.',
},
],
},
},
],
};
4 changes: 0 additions & 4 deletions TODO.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,3 @@
Todo:
- Option to remove existing files (shell.moveItemToTrash(fullPath))
- Create publish script

## TypeScript in the Electron main process

Main, shared modules used by main, `src/constants/ipc`, and `src/settings/*` are `.js`. The shell build is `yarn build` (`electron-vite build`). The page build compiles JSX in `.js` files. A move of those main sources to `.ts` starts from that build.
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
"main": "./out/main/index.js",
"scripts": {
"start": "electron-vite dev",
"test": "jest --watchAll=false",
"react-test": "jest --watchAll=false",
"test:e2e": "yarn build && node node_modules/playwright/cli.js test --config e2e/playwright.config.js",
"test:docs": "node node_modules/playwright/cli.js test --config e2e/docs/playwright.config.js",
Expand Down
44 changes: 35 additions & 9 deletions scripts/typecheck-baseline.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,31 @@ function fingerprint(line) {
return line.replace(/\(\d+,\d+\): /, ': ');
}

/** Pathless tsc continuations belong to the preceding src/ header. */
function ownedFingerprints(lines) {
let owner = '';
return lines.map((line) => {
const match = /^(src\/\S+?)\(/.exec(line);
if (match) {
owner = match[1];
return fingerprint(line);
}
return owner
? `${owner}|${line}`
: line;
});
}

function freshLines(actual, known) {
const seen = new Set(known.map(fingerprint));
return actual.filter((line) => !seen.has(fingerprint(line)));
const seen = new Set(ownedFingerprints(known));
const actualOwned = ownedFingerprints(actual);
return actual.filter( (line, i) => !seen.has(actualOwned[i]) );
}

function unusedLines(known, actual) {
const seen = new Set(ownedFingerprints(actual));
const knownOwned = ownedFingerprints(known);
return known.filter( (line, i) => !seen.has(knownOwned[i]) );
}

function main() {
Expand All @@ -40,12 +62,16 @@ function main() {
console.error(result.error || result.stderr || result.stdout);
process.exit(result.status || 1);
}
const fresh = freshLines(
diagnosticLines(`${result.stdout || ''}\n${result.stderr || ''}`),
baseline,
);
if (fresh.length) {
console.error(fresh.join('\n'));
const actual = diagnosticLines(`${result.stdout || ''}\n${result.stderr || ''}`);
const fresh = freshLines(actual, baseline);
const unused = unusedLines(baseline, actual);
if (fresh.length || unused.length) {
if (fresh.length) {
console.error(fresh.join('\n'));
}
if (unused.length) {
console.error('unused baseline:\n' + unused.join('\n'));
}
process.exit(1);
}
}
Expand All @@ -54,4 +80,4 @@ if (require.main === module) {
main();
}

module.exports = { diagnosticLines, freshLines };
module.exports = { diagnosticLines, freshLines, unusedLines, ownedFingerprints };
72 changes: 0 additions & 72 deletions scripts/typecheck-baseline.txt
Original file line number Diff line number Diff line change
Expand Up @@ -31,78 +31,6 @@ src/app/store/Run.js(630,5): error TS2554: Expected 5-6 arguments, but got 4.
src/app/store/Run.js(662,5): error TS2554: Expected 5-6 arguments, but got 4.
src/app/store/Run.js(681,5): error TS2554: Expected 5-6 arguments, but got 3.
src/app/store/Run.js(693,5): error TS2554: Expected 5-6 arguments, but got 4.
src/app/store/StoreBase.js(19,13): error TS2365: Operator '>' cannot be applied to types 'boolean' and 'number'.
src/common/utils.js(19,5): error TS2322: Type '"macos"' is not assignable to type 'Platform'.
src/common/utils.js(21,5): error TS2322: Type '"windows"' is not assignable to type 'Platform'.
src/common/utils.js(41,19): error TS2551: Property 'store' does not exist on type 'Window & typeof globalThis'. Did you mean 'Storage'?
src/electron.js(5,27): error TS2769: No overload matches this call.
The last overload gave the following error.
Argument of type 'typeof CrossProcessExports' is not assignable to parameter of type 'string'.
src/main/api.js(33,10): error TS2304: Cannot find name '__static'.
src/main/api.js(87,6): error TS2339: Property 'getCurrentWindow' does not exist on type 'typeof BrowserWindow'.
src/main/api.js(122,52): error TS2769: No overload matches this call.
Overload 1 of 4, '(command: string, options: ExecOptionsWithBufferEncoding): PromiseWithChild<{ stdout: NonSharedBuffer; stderr: NonSharedBuffer; }>', gave the following error.
Argument of type '{ shell?: boolean; cwd: any; }' is not assignable to parameter of type 'ExecOptionsWithBufferEncoding'.
Property 'encoding' is missing in type '{ shell?: boolean; cwd: any; }' but required in type 'ExecOptionsWithBufferEncoding'.
Overload 2 of 4, '(command: string, options: ExecOptionsWithStringEncoding): PromiseWithChild<{ stdout: string; stderr: string; }>', gave the following error.
Argument of type '{ shell?: boolean; cwd: any; }' is not assignable to parameter of type 'ExecOptionsWithStringEncoding'.
Types of property 'shell' are incompatible.
Type 'boolean' is not assignable to type 'string'.
Overload 3 of 4, '(command: string, options: ExecOptions): PromiseWithChild<{ stdout: string | NonSharedBuffer; stderr: string | NonSharedBuffer; }>', gave the following error.
Argument of type '{ shell?: boolean; cwd: any; }' is not assignable to parameter of type 'ExecOptions'.
Types of property 'shell' are incompatible.
Type 'boolean' is not assignable to type 'string'.
src/main/api.js(201,99): error TS2769: No overload matches this call.
Overload 1 of 4, '(command: string, options: ExecOptionsWithBufferEncoding): PromiseWithChild<{ stdout: NonSharedBuffer; stderr: NonSharedBuffer; }>', gave the following error.
Argument of type '{ shell?: boolean; }' is not assignable to parameter of type 'ExecOptionsWithBufferEncoding'.
Property 'encoding' is missing in type '{ shell?: boolean; }' but required in type 'ExecOptionsWithBufferEncoding'.
Overload 2 of 4, '(command: string, options: ExecOptionsWithStringEncoding): PromiseWithChild<{ stdout: string; stderr: string; }>', gave the following error.
Argument of type '{ shell?: boolean; }' is not assignable to parameter of type 'ExecOptionsWithStringEncoding'.
Types of property 'shell' are incompatible.
Type 'boolean' is not assignable to type 'string'.
Overload 3 of 4, '(command: string, options: ExecOptions): PromiseWithChild<{ stdout: string | NonSharedBuffer; stderr: string | NonSharedBuffer; }>', gave the following error.
Argument of type '{ shell?: boolean; }' is not assignable to parameter of type 'ExecOptions'.
Types of property 'shell' are incompatible.
Type 'boolean' is not assignable to type 'string'.
src/main/api.js(363,52): error TS2769: No overload matches this call.
Overload 1 of 4, '(command: string, options: ExecOptionsWithBufferEncoding): PromiseWithChild<{ stdout: NonSharedBuffer; stderr: NonSharedBuffer; }>', gave the following error.
Argument of type '{ shell?: boolean; }' is not assignable to parameter of type 'ExecOptionsWithBufferEncoding'.
Property 'encoding' is missing in type '{ shell?: boolean; }' but required in type 'ExecOptionsWithBufferEncoding'.
Overload 2 of 4, '(command: string, options: ExecOptionsWithStringEncoding): PromiseWithChild<{ stdout: string; stderr: string; }>', gave the following error.
Argument of type '{ shell?: boolean; }' is not assignable to parameter of type 'ExecOptionsWithStringEncoding'.
Types of property 'shell' are incompatible.
Type 'boolean' is not assignable to type 'string'.
Overload 3 of 4, '(command: string, options: ExecOptions): PromiseWithChild<{ stdout: string | NonSharedBuffer; stderr: string | NonSharedBuffer; }>', gave the following error.
Argument of type '{ shell?: boolean; }' is not assignable to parameter of type 'ExecOptions'.
Types of property 'shell' are incompatible.
Type 'boolean' is not assignable to type 'string'.
src/main/api.js(384,52): error TS2769: No overload matches this call.
Overload 1 of 4, '(command: string, options: ExecOptionsWithBufferEncoding): PromiseWithChild<{ stdout: NonSharedBuffer; stderr: NonSharedBuffer; }>', gave the following error.
Argument of type '{ shell?: boolean; }' is not assignable to parameter of type 'ExecOptionsWithBufferEncoding'.
Property 'encoding' is missing in type '{ shell?: boolean; }' but required in type 'ExecOptionsWithBufferEncoding'.
Overload 2 of 4, '(command: string, options: ExecOptionsWithStringEncoding): PromiseWithChild<{ stdout: string; stderr: string; }>', gave the following error.
Argument of type '{ shell?: boolean; }' is not assignable to parameter of type 'ExecOptionsWithStringEncoding'.
Types of property 'shell' are incompatible.
Type 'boolean' is not assignable to type 'string'.
Overload 3 of 4, '(command: string, options: ExecOptions): PromiseWithChild<{ stdout: string | NonSharedBuffer; stderr: string | NonSharedBuffer; }>', gave the following error.
Argument of type '{ shell?: boolean; }' is not assignable to parameter of type 'ExecOptions'.
Types of property 'shell' are incompatible.
Type 'boolean' is not assignable to type 'string'.
src/main/api.js(433,12): error TS2367: This comparison appears to be unintentional because the types 'number' and 'string' have no overlap.
src/main/api.js(486,12): error TS2367: This comparison appears to be unintentional because the types 'number' and 'string' have no overlap.
src/main/menu/index.js(47,26): error TS2345: Argument of type '{ label: string; submenu: ({ label: string; click(): never; type?: undefined; role?: undefined; } | { type: string; label?: undefined; click?: undefined; role?: undefined; } | { role: string; label?: undefined; click?: undefined; type?: undefined; })[]; }' is not assignable to parameter of type '{ label: string; submenu: ({ label: string; accelerator: string; click(): void; submenu?: undefined; } | { label: string; submenu: { label: string; type: string; checked: boolean; click(): void; }[]; accelerator?: undefined; click?: undefined; })[]; } | { ...; } | { ...; }'.
Type '{ label: string; submenu: ({ label: string; click(): never; type?: undefined; role?: undefined; } | { type: string; label?: undefined; click?: undefined; role?: undefined; } | { role: string; label?: undefined; click?: undefined; type?: undefined; })[]; }' is not assignable to type '{ label: string; submenu: { label: string; submenu: { label: string; type: string; checked: boolean; click(): void; }[]; }[]; }'.
Types of property 'submenu' are incompatible.
Type '({ label: string; click(): never; type?: undefined; role?: undefined; } | { type: string; label?: undefined; click?: undefined; role?: undefined; } | { role: string; label?: undefined; click?: undefined; type?: undefined; })[]' is not assignable to type '{ label: string; submenu: { label: string; type: string; checked: boolean; click(): void; }[]; }[]'.
Type '{ label: string; click(): never; type?: undefined; role?: undefined; } | { type: string; label?: undefined; click?: undefined; role?: undefined; } | { role: string; label?: undefined; click?: undefined; type?: undefined; }' is not assignable to type '{ label: string; submenu: { label: string; type: string; checked: boolean; click(): void; }[]; }'.
Property 'submenu' is missing in type '{ label: string; click(): never; type?: undefined; role?: undefined; }' but required in type '{ label: string; submenu: { label: string; type: string; checked: boolean; click(): void; }[]; }'.
src/main/menu/index.js(51,29): error TS2345: Argument of type '{ label: string; submenu: ({ role: string; type?: undefined; } | { type: string; role?: undefined; })[]; }' is not assignable to parameter of type '{ label: string; submenu: ({ label: string; accelerator: string; click(): void; submenu?: undefined; } | { label: string; submenu: { label: string; type: string; checked: boolean; click(): void; }[]; accelerator?: undefined; click?: undefined; })[]; } | { ...; } | { ...; }'.
Type '{ label: string; submenu: ({ role: string; type?: undefined; } | { type: string; role?: undefined; })[]; }' is not assignable to type '{ label: string; submenu: { label: string; submenu: { label: string; type: string; checked: boolean; click(): void; }[]; }[]; }'.
Types of property 'submenu' are incompatible.
Type '({ role: string; type?: undefined; } | { type: string; role?: undefined; })[]' is not assignable to type '{ label: string; submenu: { label: string; type: string; checked: boolean; click(): void; }[]; }[]'.
Type '{ role: string; type?: undefined; } | { type: string; role?: undefined; }' is not assignable to type '{ label: string; submenu: { label: string; type: string; checked: boolean; click(): void; }[]; }'.
Type '{ role: string; type?: undefined; }' is missing the following properties from type '{ label: string; submenu: { label: string; type: string; checked: boolean; click(): void; }[]; }': label, submenu
src/main/menu/index.js(53,42): error TS2345: Argument of type '({ label: string; submenu: ({ label: string; accelerator: string; click(): void; submenu?: undefined; } | { label: string; submenu: { label: string; type: string; checked: boolean; click(): void; }[]; accelerator?: undefined; click?: undefined; })[]; } | { ...; } | { ...; })[]' is not assignable to parameter of type '(MenuItemConstructorOptions | MenuItem)[]'.
Type '{ label: string; submenu: ({ label: string; accelerator: string; click(): void; submenu?: undefined; } | { label: string; submenu: { label: string; type: string; checked: boolean; click(): void; }[]; accelerator?: undefined; click?: undefined; })[]; } | { ...; } | { ...; }' is not assignable to type 'MenuItemConstructorOptions | MenuItem'.
Type '{ label: string; submenu: ({ label: string; accelerator: string; click(): void; submenu?: undefined; } | { label: string; submenu: { label: string; type: string; checked: boolean; click(): void; }[]; accelerator?: undefined; click?: undefined; })[]; }' is not assignable to type 'MenuItemConstructorOptions | MenuItem'.
Type '{ label: string; submenu: ({ label: string; accelerator: string; click(): void; submenu?: undefined; } | { label: string; submenu: { label: string; type: string; checked: boolean; click(): void; }[]; accelerator?: undefined; click?: undefined; })[]; }' is missing the following properties from type 'MenuItem': accelerator, accessibilityLabel, checked, click, and 11 more.
1 change: 1 addition & 0 deletions src/__static.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
declare const __static: string;
2 changes: 1 addition & 1 deletion src/app/paths.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ it( 'joins, names, and quotes a path', () => {
} );

it( 'an input file reports the plain name, base, and directory', () => {
const file = new InputFile( { id: 'run-7' }, '/data/primates.fasta' );
const file = new InputFile( { id: 7 }, '/data/primates.fasta' );
expect( file.name ).toBe( 'primates' );
expect( file.base ).toBe( 'primates.fasta' );
expect( file.filename ).toBe( 'primates.fasta' );
Expand Down
8 changes: 4 additions & 4 deletions src/app/store/astral.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,22 +28,22 @@ function emit( list, payload ) {
it( 'startAstral starts ASTRAL', async () => {
const startAstral = jest.fn( async () => {} );
bridge( { startAstral } );
const run = new Run( { onError() {} }, 'run-7' );
const run = new Run( { onError() {} }, 7 );
run.setOutputDir( '/out' );

await run.startAstral();

expect( run.running ).toBe( true );
expect( startAstral ).toHaveBeenCalledWith( {
id: 'run-7',
id: 7,
binaryName: run.binary.value,
args: run.args,
} );
} );

it( 'an ASTRAL exit code is recorded for that run', () => {
const { listeners, stops } = bridge();
const run = new Run( { onError() {} }, 'run-7' );
const run = new Run( { onError() {} }, 7 );
run.running = true;
run.setOutputDir( '/out' );

Expand All @@ -52,7 +52,7 @@ it( 'an ASTRAL exit code is recorded for that run', () => {
expect( run.finished ).toBe( false );
expect( run.running ).toBe( true );

emit( listeners.success, { id: 'run-7', exitCode: 3 } );
emit( listeners.success, { id: 7, exitCode: 3 } );
expect( run.exitCode ).toBe( 3 );
expect( run.resultDir ).toBe( '/out' );
expect( run.finished ).toBe( true );
Expand Down
8 changes: 4 additions & 4 deletions src/app/store/cancelRun.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,12 @@ import Run from './Run';
it( 'the cancel control uses cancelRun', () => {
const cancelRun = jest.fn();
window.rendererBridge = { cancelRun };
const run = new Run( { onError() {} }, 'run-7' );
const run = new Run( { onError() {} }, 7 );
run.running = true;

run.cancel();

expect( cancelRun ).toHaveBeenCalledWith( 'run-7' );
expect( cancelRun ).toHaveBeenCalledWith( 7 );
expect( run.running ).toBe( false );
} );

Expand All @@ -37,7 +37,7 @@ it( 'cancel before the run is tracked does not start it', async () => {
cancelRun,
parseAlignment: () => new Promise( () => {} ),
};
const run = new Run( { onError() {} }, 'run-7' );
const run = new Run( { onError() {} }, 7 );
run.setOutputDir( outputDir );
run.addAlignments( [
{ path: '/data/a.fasta' },
Expand All @@ -59,7 +59,7 @@ it( 'cancel before the run is tracked does not start it', async () => {
waiters.forEach( ( release ) => release() );
await pending;
expect( startRun ).not.toHaveBeenCalled();
expect( cancelRun ).toHaveBeenCalledWith( 'run-7' );
expect( cancelRun ).toHaveBeenCalledWith( 7 );
} finally {
fs.rmSync( outputDir, { recursive: true, force: true } );
}
Expand Down
2 changes: 1 addition & 1 deletion src/app/store/checkOutputName.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ it( 'the output-name check uses checkOutput', async () => {
resultFilenames: ['tree.raxml.log'],
} ) );
window.rendererBridge = { checkOutput };
const run = new Run( {}, 'run-7' );
const run = new Run( {}, 7 );
run.setOutputDir( '/data/out' );
run.setOutputName( 'tree' );

Expand Down
Loading
Loading