diff --git a/scripts/e2e/lib/kitchen-sink-plugin/assertions.mjs b/scripts/e2e/lib/kitchen-sink-plugin/assertions.mjs index a21b9f58f6d..8219f12db01 100644 --- a/scripts/e2e/lib/kitchen-sink-plugin/assertions.mjs +++ b/scripts/e2e/lib/kitchen-sink-plugin/assertions.mjs @@ -174,7 +174,7 @@ function assertExpectedDiagnostics(surfaceMode, errorMessages) { throw new Error(`unexpected kitchen-sink diagnostic error: ${message}`); } } - if (surfaceMode === "full") { + if (surfaceMode === "full" && process.env.KITCHEN_SINK_REQUIRE_ALL_DIAGNOSTICS === "1") { for (const message of expectedErrorMessages) { if (!errorMessages.has(message)) { throw new Error(`missing expected kitchen-sink diagnostic error: ${message}`);