Skip to content

fix: Use HMR API for dev server communication #3114

fix: Use HMR API for dev server communication

fix: Use HMR API for dev server communication #3114

Triggered via pull request January 22, 2025 04:59
Status Failure
Total duration 3m 11s
Artifacts

validate.yml

on: pull_request
Matrix: template
Fit to window
Zoom out
Zoom in

Annotations

6 errors
e2e/tests/output-structure.test.ts > Output Directory Structure > should generate ESM background script when type=module: packages/wxt/e2e/tests/output-structure.test.ts#L277
Error: Snapshot `Output Directory Structure > should generate ESM background script when type=module 1` mismatched - Expected + Received @@ -1,24 +1,19 @@ ".output/chrome-mv3/background.js ---------------------------------------- - var _a, _b; import { l as logHello, i as initPlugins } from "./chunks/_virtual_wxt-plugins-OjKtWpmY.js"; + import "http://localhost:3000/@id/wxt/background-client"; function defineBackground(arg) { if (arg == null || typeof arg === "function") return { main: arg }; return arg; } const definition = defineBackground({ type: "module", main() { logHello("background"); } }); - // @ts-expect-error - ((_b = (_a = globalThis.browser) == null ? void 0 : _a.runtime) == null ? void 0 : _b.id) == null ? globalThis.chrome : ( - // @ts-expect-error - globalThis.browser - ); function print(method, ...args) { return; } const logger = { debug: (...args) => print(console.debug, ...args), ❯ e2e/tests/output-structure.test.ts:277:8
e2e/tests/output-structure.test.ts > Output Directory Structure > should generate IIFE background script when type=undefined: packages/wxt/e2e/tests/output-structure.test.ts#L362
Error: Snapshot `Output Directory Structure > should generate IIFE background script when type=undefined 1` mismatched - Expected + Received @@ -1,10 +1,9 @@ ".output/chrome-mv3/background.js ---------------------------------------- var background = function() { "use strict"; - var _a, _b; function defineBackground(arg) { if (arg == null || typeof arg === "function") return { main: arg }; return arg; } function logHello(name) { @@ -17,15 +16,10 @@ } }); background; function initPlugins() { } - // @ts-expect-error - ((_b = (_a = globalThis.browser) == null ? void 0 : _a.runtime) == null ? void 0 : _b.id) == null ? globalThis.chrome : ( - // @ts-expect-error - globalThis.browser - ); function print(method, ...args) { return; } const logger = { debug: (...args) => print(console.debug, ...args), ❯ e2e/tests/output-structure.test.ts:362:8
tests
Process completed with exit code 1.
e2e/tests/output-structure.test.ts > Output Directory Structure > should generate ESM background script when type=module: packages/wxt/e2e/tests/output-structure.test.ts#L277
Error: Snapshot `Output Directory Structure > should generate ESM background script when type=module 1` mismatched - Expected + Received @@ -1,24 +1,19 @@ ".output/chrome-mv3/background.js ---------------------------------------- - var _a, _b; import { l as logHello, i as initPlugins } from "./chunks/_virtual_wxt-plugins-OjKtWpmY.js"; + import "http://localhost:3000/@id/wxt/background-client"; function defineBackground(arg) { if (arg == null || typeof arg === "function") return { main: arg }; return arg; } const definition = defineBackground({ type: "module", main() { logHello("background"); } }); - // @ts-expect-error - ((_b = (_a = globalThis.browser) == null ? void 0 : _a.runtime) == null ? void 0 : _b.id) == null ? globalThis.chrome : ( - // @ts-expect-error - globalThis.browser - ); function print(method, ...args) { return; } const logger = { debug: (...args) => print(console.debug, ...args), ❯ e2e/tests/output-structure.test.ts:277:8
e2e/tests/output-structure.test.ts > Output Directory Structure > should generate IIFE background script when type=undefined: packages/wxt/e2e/tests/output-structure.test.ts#L362
Error: Snapshot `Output Directory Structure > should generate IIFE background script when type=undefined 1` mismatched - Expected + Received @@ -1,10 +1,9 @@ ".output/chrome-mv3/background.js ---------------------------------------- var background = function() { "use strict"; - var _a, _b; function defineBackground(arg) { if (arg == null || typeof arg === "function") return { main: arg }; return arg; } function logHello(name) { @@ -17,15 +16,10 @@ } }); background; function initPlugins() { } - // @ts-expect-error - ((_b = (_a = globalThis.browser) == null ? void 0 : _a.runtime) == null ? void 0 : _b.id) == null ? globalThis.chrome : ( - // @ts-expect-error - globalThis.browser - ); function print(method, ...args) { return; } const logger = { debug: (...args) => print(console.debug, ...args), ❯ e2e/tests/output-structure.test.ts:362:8
windows-tests
Process completed with exit code 1.