/** * E2EScriptFixExecutor — uses an LLM to update a failing Playwright script. * * Receives the current script and a fix instruction from the E2E test editor chat, * asks the LLM to produce a revised script, and saves it via the API. */ import type { ApiClient } from '../api-client'; import type { AgentChatMode, AgentServerConfig, CommandResult, ProjectConfigResponse } from '../types'; export interface E2eScriptFixPayload { testCaseId?: unknown; message?: unknown; currentScript?: unknown; } export interface ExecuteE2eScriptFixOptions { payload: E2eScriptFixPayload; client: ApiClient; tenantCode?: string; projectCode?: string; agentId?: string; commandId?: string; serverConfig?: AgentServerConfig; activeChatMode?: AgentChatMode; availableChatModes?: AgentChatMode[]; projectDir?: string; projectConfig?: ProjectConfigResponse; mcpConfigPath?: string; browserLocalPort?: number; } /** * Extract a TypeScript/JavaScript code block from an LLM response string. * Returns null if no code block is found. */ export declare function extractScriptFromResponse(response: string): string | null; /** * Execute an E2E script fix command. * * Combines the current Playwright script with the user's fix instruction, * sends it to the LLM, extracts the revised script, and saves it via the API. */ export declare function executeE2eScriptFix(options: ExecuteE2eScriptFixOptions): Promise; //# sourceMappingURL=e2e-script-fix-executor.d.ts.map