diff options
| author | Tianren Dong <tianrendong.dtr@gmail.com> | 2026-09-26 19:24:12 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2026-09-26 19:24:12 -0400 |
| commit | b8dd042d899df98898a299cdb1e030f19983b835 (patch) | |
| tree | 4c7221441428a086e93f2767a9fb332ee97c9995 /test-suite/unit/background-policy.test.mjs | |
| parent | df1472b8c777d40daa70da23115f4c8f5afb6623 (diff) | |
| parent | 238f347a03b2cefb21198bb78a90699e931d8504 (diff) | |
Merge pull request #21 from tianrendong/fix/hidden-input-uploads-screenshots
Report hidden-tab input, append targeted typing, smarter uploads, prune screenshots; release 0.15.54
Diffstat (limited to 'test-suite/unit/background-policy.test.mjs')
| -rw-r--r-- | test-suite/unit/background-policy.test.mjs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/test-suite/unit/background-policy.test.mjs b/test-suite/unit/background-policy.test.mjs index fe71634..2388d78 100644 --- a/test-suite/unit/background-policy.test.mjs +++ b/test-suite/unit/background-policy.test.mjs @@ -50,7 +50,7 @@ function piHarness({ session = "alpha", send } = {}) { formatChromeInspect: JSON.stringify, summarizeActionResult: () => "", formatIncludedSnapshotText: (_r, text) => text, describeTypeEvidence: () => [], formatCdpResult: (_method, value) => ({ content: [{ type: "text", text: JSON.stringify(value) }], details: { value } }), workspaceCwd: () => ctx.cwd, ...path, - mkdir: async () => {}, writeFile: async (...args) => writes.push(args), + mkdir: async () => {}, writeFile: async (...args) => writes.push(args), pruneScreenshotDir: async () => 0, }; const registrations = indexSource.slice(indexSource.indexOf("function registerChromeTools(pi:"), indexSource.lastIndexOf("\n}")); vm.runInNewContext(stripTypeScriptTypes([ @@ -292,6 +292,7 @@ function workerHarness({ withWindows = true } = {}) { w, chrome, calls, tabs, focusedWindow: () => focusedWindow, cdpResult: (method) => method === "Page.captureScreenshot" ? { data: "c2NyZWVuc2hvdA==" } : method === "DOM.requestNode" ? { nodeId: 1 } + : method === "Runtime.callFunctionOn" ? { result: { type: "object", value: { tag: "INPUT", isFile: true } } } : { result: { type: "boolean", value: true, objectId: "file-input" } }, }; return h; |
