/** * Custom Playwright reporter that extends the JSON output with parallelMode * information needed for optimal shard packing. * * Usage: * npx playwright test --list --reporter=@empiricalrun/reporter/shard-info */ import type { FullConfig, FullResult, Reporter, Suite } from "@playwright/test/reporter"; type ParallelMode = "none" | "default" | "serial" | "parallel"; export interface ShardInfoSpec { id: string; title: string; file: string; line: number; column: number; tests: { projectId: string; projectName: string; }[]; } export interface ShardInfoSuite { title: string; file: string; line: number; column: number; parallelMode: ParallelMode; hasBeforeAllHooks: boolean; hasAfterAllHooks: boolean; specs: ShardInfoSpec[]; suites: ShardInfoSuite[]; } export interface ShardInfoProject { name: string; fullyParallel: boolean; } export interface ShardInfoReport { config: { rootDir: string; fullyParallel: boolean; }; projects: ShardInfoProject[]; suites: ShardInfoSuite[]; } declare class ShardInfoReporter implements Reporter { config: FullConfig; suite: Suite; onBegin(config: FullConfig, suite: Suite): void; onEnd(_result: FullResult): void; private serializeReport; private serializeSuite; private serializeSpec; } export default ShardInfoReporter; //# sourceMappingURL=shard-info-reporter.d.ts.map