()
| 30 | const rawError = (message: string): Error => new Error(message); |
| 31 | |
| 32 | const captureReports = (): { |
| 33 | readonly calls: Array<{ error: unknown; context: FrontendErrorContext }>; |
| 34 | readonly report: (error: unknown, context: FrontendErrorContext) => void; |
| 35 | } => { |
| 36 | const calls: Array<{ error: unknown; context: FrontendErrorContext }> = []; |
| 37 | return { calls, report: (error, ctx) => calls.push({ error, context: ctx }) }; |
| 38 | }; |
| 39 | |
| 40 | describe("frontend error reporting", () => { |
| 41 | it("extracts stable messages from structured failures", () => { |
no test coverage detected