diff --git a/packages/html-reporter/src/testErrorView.tsx b/packages/html-reporter/src/testErrorView.tsx index 881c420c22..d7a979a9d9 100644 --- a/packages/html-reporter/src/testErrorView.tsx +++ b/packages/html-reporter/src/testErrorView.tsx @@ -20,17 +20,18 @@ import './testErrorView.css'; import type { ImageDiff } from '@web/shared/imageDiffView'; import { ImageDiffView } from '@web/shared/imageDiffView'; import { TestAttachment } from './types'; +import { fixTestInstructions } from '@web/prompts'; export const TestErrorView: React.FC<{ error: string; testId?: string; - prompt?: TestAttachment; -}> = ({ error, testId, prompt }) => { + context?: TestAttachment; +}> = ({ error, testId, context }) => { return ( - {prompt && ( + {context && (
- +
)}
@@ -47,14 +48,14 @@ export const CodeSnippet = ({ code, children, testId }: React.PropsWithChildren< ); }; -const PromptButton: React.FC<{ prompt: TestAttachment }> = ({ prompt }) => { +const PromptButton: React.FC<{ context: TestAttachment }> = ({ context }) => { const [copied, setCopied] = React.useState(false); return