Files
triggerdotdev--trigger.dev/internal-packages/testcontainers/src/sequencer.d.cts
T
2026-07-13 13:32:57 +08:00

14 lines
729 B
TypeScript

import type { TestSequencer, TestSpecification, Vitest } from "vitest/node";
/**
* Duration-weighted `--shard=i/N`: bin-packs test files by recorded duration (test-timings.json at
* the repo root) so each shard does roughly equal work. The runtime lives in `sequencer.cjs` (plain
* JS, so vitest config loading can load it on any node - see that file's header); this declaration
* supplies the types for configs that wire it via `sequence: { sequencer: DurationShardingSequencer }`.
*/
export declare class DurationShardingSequencer implements TestSequencer {
constructor(ctx: Vitest);
sort(files: TestSpecification[]): Promise<TestSpecification[]>;
shard(files: TestSpecification[]): Promise<TestSpecification[]>;
}