function clearBundles
clearBundles(build: BuildState): void

Invalidates a group's compiled bundles so the next run rebuilds them from disk.

Both go together: /tests.js serves allTestCode and /filtered-tests.js serves filteredTestCode verbatim, so clearing only the full bundle leaves a stale filtered one servable — and a watch-mode delete would then rerun tests from a file that no longer exists.

import * as RunState from './run-state.ts';

const { build } = RunState.newGroup();
build.allTestCode = 'bundled js…';
RunState.clearBundles(build);
build.allTestCode; // null — the next run rebuilds both bundles from disk

Parameters

Return Type

void

Usage

import { clearBundles } from "lib/setup/run-state.ts";