Skip to content

Commit 832e5bc

Browse files
jrusso1020claude
andcommitted
test(producer): run the auto capture lock test only with chrome-headless-shell
Signed: Rames Jusso Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
1 parent 67edb09 commit 832e5bc

1 file changed

Lines changed: 7 additions & 1 deletion

File tree

‎packages/producer/src/services/distributed/plan.test.ts‎

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ import {
2727
writeFileSync,
2828
} from "node:fs";
2929
import { tmpdir } from "node:os";
30-
import { join } from "node:path";
30+
import { basename, join } from "node:path";
3131
import {
3232
applyConcreteGpuScreenshotClamp,
3333
_setDownloadFetchForTests,
@@ -36,6 +36,7 @@ import {
3636
getFfmpegBinary,
3737
getFfprobeBinary,
3838
encodeAac,
39+
resolveHeadlessShellPath,
3940
} from "@hyperframes/engine";
4041
import { recomputePlanHashFromPlanDir } from "../render/stages/freezePlan.js";
4142
import { defaultLogger } from "../../logger.js";
@@ -635,6 +636,11 @@ describe("plan() and PRODUCER_FORCE_SCREENSHOT=auto", () => {
635636
it.skipIf(process.platform !== "linux")(
636637
"locks screenshot capture for every chunk when the page has a WebGL canvas",
637638
async () => {
639+
// Only chrome-headless-shell has BeginFrame; any other browser plans the same for every page.
640+
if (!basename(resolveHeadlessShellPath() ?? "").startsWith("chrome-headless-shell")) {
641+
console.warn("[plan.test] skipping the auto capture lock test: no chrome-headless-shell");
642+
return;
643+
}
638644
const webgl = FIXTURE_HTML.replace("</body>", `${WEBGL_CANVAS}</body>`);
639645
expect(webgl).not.toBe(FIXTURE_HTML);
640646
expect(await planLockedCapture(webgl, "auto-webgl", "auto")).toEqual({

0 commit comments

Comments
 (0)