Skip to content
Source
Sign inSign up
pingdotgg/t3code

fix(server): agent recordings honor the browser frame rate setting #23895

Mergedjuliusmarmingemerged 6 commits intomain fromrefs/pull/23895/headmerged by juliusmarminge View on GitHub

Showing 6 changed files with 87 additions and 5 deletions (loading 3).

x
0 of 6 viewed, 6 left
77 additions and 1 deletionapps/server/src/preview/ServerBrowser.test.tsModified
View file
@@ -1,4 +1,5 @@
import * as NodeEvents from "node:events";
+import * as NodeVM from "node:vm";
// @effect-diagnostics-next-line nodeBuiltinImport:off - Playwright download mocks perform real file operations outside the Effect runtime.
import * as NodeFSP from "node:fs/promises";
​
@@ -6,6 +7,7 @@
import * as HostProcess from "@t3tools/shared/HostProcess";
import { it } from "@effect/vitest";
import {
+ type BrowserRecordingFrameRate,
EnvironmentId,
PreviewTabId,
ProviderInstanceId,
@@ -49,7 +51,7 @@
return context as unknown as BrowserContext;
async scratchPage() {
- return makeContext().page as unknown as Page;
+ return makeEncoderPage() as unknown as Page;
async connectDesktopPage(endpoint: string) {
const context = makeContext();
@@ -212,7 +214,50 @@
return context;
​
+// Runs the real encoder script against fake canvas and MediaRecorder globals.