/** * Runtime parser for test file naming convention * Supports: test.runtime1+runtime2.modifier.ts * Examples: * - test.node.ts * - test.chromium.ts * - test.node+chromium.ts * - test.deno+bun.ts * - test.all.ts (runs on all runtimes) * - test.chromium.nonci.ts */ export type Runtime = 'node' | 'chromium' | 'deno' | 'bun'; export type Modifier = 'nonci'; export interface ParsedFilename { baseName: string; runtimes: Runtime[]; modifiers: Modifier[]; extension: string; isLegacy: boolean; original: string; } export interface ParserConfig { strictUnknownRuntime?: boolean; defaultRuntimes?: Runtime[]; } /** * Parse a test filename to extract runtimes, modifiers, and detect legacy patterns * Algorithm: Right-to-left token analysis from the extension */ export declare function parseTestFilename(filePath: string, config?: ParserConfig): ParsedFilename; /** * Check if a filename uses legacy naming convention */ export declare function isLegacyFilename(fileName: string): boolean; /** * Get the suggested new filename for a legacy filename */ export declare function getLegacyMigrationTarget(fileName: string): string | null; /** * Docker test file information */ export interface DockerTestFileInfo { baseName: string; variant: string; isDockerTest: true; original: string; } /** * Check if a filename matches the Docker test pattern: *.{variant}.docker.sh * Examples: test.latest.docker.sh, test.integration.npmci.docker.sh */ export declare function isDockerTestFile(fileName: string): boolean; /** * Parse a Docker test filename to extract variant and base name * Pattern: test.{baseName}.{variant}.docker.sh * Examples: * - test.latest.docker.sh -> { baseName: 'test', variant: 'latest' } * - test.integration.npmci.docker.sh -> { baseName: 'test.integration', variant: 'npmci' } */ export declare function parseDockerTestFilename(filePath: string): DockerTestFileInfo; /** * Map a Docker variant to its corresponding Dockerfile path * "latest" -> "Dockerfile" * Other variants -> "Dockerfile_{variant}" */ export declare function mapVariantToDockerfile(variant: string, baseDir: string): string;