fix(browser): report mismatched event family selection as unknown in capture comparison (#2239)

* fix(browser): report mismatched event family selection as unknown in capture comparison

* fix(browser): retain selected event families and unknown coverage

Fold the complementary implementation from #2253 into the earlier #2239 proposal, retaining the original contribution history.

Co-authored-by: itsF4LCON <107556180+itsF4LCON@users.noreply.github.com>

---------

Co-authored-by: LouisChen <3361008+chqcjq@users.noreply.github.com>
Co-authored-by: morluto <76467478+morluto@users.noreply.github.com>
Co-authored-by: itsF4LCON <107556180+itsF4LCON@users.noreply.github.com>
This commit is contained in:
LouisChen
2026-10-13 02:36:45 +08:00
committed by GitHub
co-authored by LouisChen morluto itsF4LCON
parent aeee5074d1
commit 0043d9b134
13 changed files with 206 additions and 15 deletions
+2 -14
View File
@@ -5,6 +5,7 @@ import { IDENTIFIER_PATTERN } from "./stringPatterns.js";
import { localPathStringSchema } from "./localPath.js";
import { browserNetworkContentSelectionSchema } from "./browserNetworkEvidence.js";
import { browserScenarioEventFamilySchema } from "./browserScenarioCaptureValues.js";
import {
browserEndpointSchema,
@@ -289,20 +290,7 @@ export const browserScenarioCaptureSchema = z
.strictObject({
after_each_step: z.array(snapshotKindSchema).default([]),
at_end: z.array(snapshotKindSchema).default(["url"]),
events: z
.array(
z.enum([
"console",
"page-errors",
"network",
"websockets",
"frames",
"workers",
"popups",
"downloads",
]),
)
.default([]),
events: z.array(browserScenarioEventFamilySchema).default([]),
network: browserNetworkContentSelectionSchema,
})
.default({