diff options
author | 2022-12-12 00:40:00 -0800 | |
---|---|---|
committer | 2022-12-12 00:40:00 -0800 | |
commit | 14efd03b48019255f636772eea0ff161e3807815 (patch) | |
tree | 409859ae8e944a1d6f673f072e7df6534ad117fb | |
parent | d5b11be769d25d8b096f4dd9c853555a52693f93 (diff) | |
download | bun-14efd03b48019255f636772eea0ff161e3807815.tar.gz bun-14efd03b48019255f636772eea0ff161e3807815.tar.zst bun-14efd03b48019255f636772eea0ff161e3807815.zip |
:camera:
-rw-r--r-- | test/snapshots/bundled-entry-point.hmr.debug.js | 2 | ||||
-rw-r--r-- | test/snapshots/cjs-transform-shouldnt-have-static-imports-in-cjs-function.hmr.debug.js | 6 | ||||
-rw-r--r-- | test/snapshots/export.hmr.debug.js | 2 | ||||
-rw-r--r-- | test/snapshots/lodash-regexp.hmr.debug.js | 4 | ||||
-rw-r--r-- | test/snapshots/multiple-var.hmr.debug.js | 1 | ||||
-rw-r--r-- | test/snapshots/multiple-var.hmr.js | 1 | ||||
-rw-r--r-- | test/snapshots/number-literal-bug.hmr.debug.js | 3 | ||||
-rw-r--r-- | test/snapshots/number-literal-bug.hmr.js | 3 | ||||
-rw-r--r-- | test/snapshots/optional-chain-with-function.hmr.debug.js | 3 | ||||
-rw-r--r-- | test/snapshots/optional-chain-with-function.hmr.js | 3 | ||||
-rw-r--r-- | test/snapshots/package-json-exports/index.hmr.debug.js | 10 | ||||
-rw-r--r-- | test/snapshots/react-context-value-func.hmr.debug.tsx | 3 | ||||
-rw-r--r-- | test/snapshots/react-context-value-func.hmr.tsx | 3 | ||||
-rw-r--r-- | test/snapshots/simple-lit-example.hmr.debug.ts | 3 | ||||
-rw-r--r-- | test/snapshots/simple-lit-example.hmr.ts | 3 | ||||
-rw-r--r-- | test/snapshots/spread_with_key.hmr.debug.tsx | 3 |
16 files changed, 21 insertions, 32 deletions
diff --git a/test/snapshots/bundled-entry-point.hmr.debug.js b/test/snapshots/bundled-entry-point.hmr.debug.js index 6a93af736..696b793ae 100644 --- a/test/snapshots/bundled-entry-point.hmr.debug.js +++ b/test/snapshots/bundled-entry-point.hmr.debug.js @@ -1,5 +1,5 @@ import { -__require as require +__require as require_ab102cbd93061951 } from "http://localhost:8080/bun:wrap"; import { __HMRClient as Bun diff --git a/test/snapshots/cjs-transform-shouldnt-have-static-imports-in-cjs-function.hmr.debug.js b/test/snapshots/cjs-transform-shouldnt-have-static-imports-in-cjs-function.hmr.debug.js index b862421e6..89a53d944 100644 --- a/test/snapshots/cjs-transform-shouldnt-have-static-imports-in-cjs-function.hmr.debug.js +++ b/test/snapshots/cjs-transform-shouldnt-have-static-imports-in-cjs-function.hmr.debug.js @@ -10,9 +10,9 @@ __FastRefreshRuntime as FastRefresh } from "http://localhost:8080/bun:wrap"; import _login from "http://localhost:8080/_login.js"; import _auth from "http://localhost:8080/_auth.js"; -import * as _loginReally from "http://localhost:8080/_login.js"; -import * as _loginReally2 from "http://localhost:8080/_login.js"; -import * as _authReally from "http://localhost:8080/_auth.js"; +import* as _loginReally from "http://localhost:8080/_login.js"; +import* as _loginReally2 from "http://localhost:8080/_login.js"; +import* as _authReally from "http://localhost:8080/_auth.js"; var hmr = new FastHMR(1284442761, "cjs-transform-shouldnt-have-static-imports-in-cjs-function.js", FastRefresh), exports = hmr.exports; (hmr._load = function() { function test() { diff --git a/test/snapshots/export.hmr.debug.js b/test/snapshots/export.hmr.debug.js index dbe3fae5d..c0a5f9e02 100644 --- a/test/snapshots/export.hmr.debug.js +++ b/test/snapshots/export.hmr.debug.js @@ -9,7 +9,7 @@ import { __FastRefreshRuntime as FastRefresh } from "http://localhost:8080/bun:wrap"; import what from "http://localhost:8080/_auth.js"; -import * as where from "http://localhost:8080/_auth.js"; +import* as where from "http://localhost:8080/_auth.js"; var hmr = new FastHMR(1805832743, "export.js", FastRefresh), exports = hmr.exports; (hmr._load = function() { var yoyoyo = "yoyoyo"; diff --git a/test/snapshots/lodash-regexp.hmr.debug.js b/test/snapshots/lodash-regexp.hmr.debug.js index b7f6f9d12..e78c40c41 100644 --- a/test/snapshots/lodash-regexp.hmr.debug.js +++ b/test/snapshots/lodash-regexp.hmr.debug.js @@ -1,5 +1,5 @@ import { -__require as require +__require as require_ab102cbd93061951 } from "http://localhost:8080/bun:wrap"; import { __HMRClient as Bun @@ -12,7 +12,7 @@ import { __FastRefreshRuntime as FastRefresh } from "http://localhost:8080/bun:wrap"; import * as $75175720 from "http://localhost:8080/node_modules/lodash/lodash.js"; -var { shuffle} = require($75175720); +var {shuffle} = require_ab102cbd93061951($75175720); var hmr = new FastHMR(2675673186, "lodash-regexp.js", FastRefresh), exports = hmr.exports; (hmr._load = function() { function test() { diff --git a/test/snapshots/multiple-var.hmr.debug.js b/test/snapshots/multiple-var.hmr.debug.js index d24b4d243..1d16f25d9 100644 --- a/test/snapshots/multiple-var.hmr.debug.js +++ b/test/snapshots/multiple-var.hmr.debug.js @@ -10,7 +10,6 @@ __FastRefreshRuntime as FastRefresh } from "http://localhost:8080/bun:wrap"; var hmr = new FastHMR(1943563621, "multiple-var.js", FastRefresh), exports = hmr.exports; (hmr._load = function() { - var foo = true; globalThis.TRUE_BUT_WE_CANT_TREESHAKE_IT = true; if (globalThis.TRUE_BUT_WE_CANT_TREESHAKE_IT) ({ foo } = { foo: false }); diff --git a/test/snapshots/multiple-var.hmr.js b/test/snapshots/multiple-var.hmr.js index ac54f3ea4..4f3d23309 100644 --- a/test/snapshots/multiple-var.hmr.js +++ b/test/snapshots/multiple-var.hmr.js @@ -10,7 +10,6 @@ __FastRefreshRuntime as FastRefresh } from "http://localhost:8080/bun:wrap"; var hmr = new FastHMR(1943563621, "multiple-var.js", FastRefresh), exports = hmr.exports; (hmr._load = function() { - var foo = true; globalThis.TRUE_BUT_WE_CANT_TREESHAKE_IT = true; if (globalThis.TRUE_BUT_WE_CANT_TREESHAKE_IT) ({ foo } = { foo: false }); diff --git a/test/snapshots/number-literal-bug.hmr.debug.js b/test/snapshots/number-literal-bug.hmr.debug.js index 7f06df649..8c2b5a6cf 100644 --- a/test/snapshots/number-literal-bug.hmr.debug.js +++ b/test/snapshots/number-literal-bug.hmr.debug.js @@ -11,9 +11,8 @@ __FastRefreshRuntime as FastRefresh var hmr = new FastHMR(472725871, "number-literal-bug.js", FastRefresh), exports = hmr.exports; (hmr._load = function() { function test() { - const precision = 10; try { - parseFloat(0 .toPrecision(precision) + "1"); + parseFloat(0 .toPrecision(10) + "1"); } catch (exception) { throw new Error("Test Failed", exception); } diff --git a/test/snapshots/number-literal-bug.hmr.js b/test/snapshots/number-literal-bug.hmr.js index eef2a876e..7e444dd25 100644 --- a/test/snapshots/number-literal-bug.hmr.js +++ b/test/snapshots/number-literal-bug.hmr.js @@ -11,9 +11,8 @@ __FastRefreshRuntime as FastRefresh var hmr = new FastHMR(472725871, "number-literal-bug.js", FastRefresh), exports = hmr.exports; (hmr._load = function() { function test() { - const precision = 10; try { - parseFloat(0 .toPrecision(precision) + "1"); + parseFloat(0 .toPrecision(10) + "1"); } catch (exception) { throw new Error("Test Failed", exception); } diff --git a/test/snapshots/optional-chain-with-function.hmr.debug.js b/test/snapshots/optional-chain-with-function.hmr.debug.js index 4ad140c1e..f84290468 100644 --- a/test/snapshots/optional-chain-with-function.hmr.debug.js +++ b/test/snapshots/optional-chain-with-function.hmr.debug.js @@ -12,9 +12,8 @@ var hmr = new FastHMR(2145684817, "optional-chain-with-function.js", FastRefresh (hmr._load = function() { function test() { try { - const multipleSecondaryValues = undefined; const ratings = ["123"]; - var bar = multipleSecondaryValues?.map((value) => false); + var bar = undefined?.map((value) => false); bar = bar?.multipleSecondaryValues?.map((value) => false); bar = bar?.bar?.multipleSecondaryValues?.map((value) => false); bar = {}?.bar?.multipleSecondaryValues?.map((value) => false); diff --git a/test/snapshots/optional-chain-with-function.hmr.js b/test/snapshots/optional-chain-with-function.hmr.js index 5f0489926..3a479ffce 100644 --- a/test/snapshots/optional-chain-with-function.hmr.js +++ b/test/snapshots/optional-chain-with-function.hmr.js @@ -12,9 +12,8 @@ var hmr = new FastHMR(2145684817, "optional-chain-with-function.js", FastRefresh (hmr._load = function() { function test() { try { - const multipleSecondaryValues = undefined; const ratings = ["123"]; - var bar = multipleSecondaryValues?.map((value) => false); + var bar = undefined?.map((value) => false); bar = bar?.multipleSecondaryValues?.map((value) => false); bar = bar?.bar?.multipleSecondaryValues?.map((value) => false); bar = {}?.bar?.multipleSecondaryValues?.map((value) => false); diff --git a/test/snapshots/package-json-exports/index.hmr.debug.js b/test/snapshots/package-json-exports/index.hmr.debug.js index 30099d095..043d7ac48 100644 --- a/test/snapshots/package-json-exports/index.hmr.debug.js +++ b/test/snapshots/package-json-exports/index.hmr.debug.js @@ -1,5 +1,5 @@ import { -__require as require +__require as require_ab102cbd93061951 } from "http://localhost:8080/bun:wrap"; import { __HMRClient as Bun @@ -12,13 +12,13 @@ import { __FastRefreshRuntime as FastRefresh } from "http://localhost:8080/bun:wrap"; import * as $a4de9925 from "http://localhost:8080/package-json-exports/node_modules/inexact/browser/index.js"; -var InexactRoot = require($a4de9925); +var InexactRoot = require_ab102cbd93061951($a4de9925); import * as $725c641 from "http://localhost:8080/package-json-exports/node_modules/inexact/browser/dir/file.js"; -var InexactFile = require($725c641); +var InexactFile = require_ab102cbd93061951($725c641); import * as $fbe61cb7 from "http://localhost:8080/package-json-exports/node_modules/inexact/browser/foo.js"; -var ExactFile = require($fbe61cb7); +var ExactFile = require_ab102cbd93061951($fbe61cb7); import * as $6a256e60 from "http://localhost:8080/package-json-exports/node_modules/js-only-exports/browser/js-file.js"; -var JSFileExtensionOnly = require($6a256e60); +var JSFileExtensionOnly = require_ab102cbd93061951($6a256e60); var hmr = new FastHMR(879772149, "package-json-exports/index.js", FastRefresh), exports = hmr.exports; (hmr._load = function() { async function test() { diff --git a/test/snapshots/react-context-value-func.hmr.debug.tsx b/test/snapshots/react-context-value-func.hmr.debug.tsx index a31263ff9..b781ea7f9 100644 --- a/test/snapshots/react-context-value-func.hmr.debug.tsx +++ b/test/snapshots/react-context-value-func.hmr.debug.tsx @@ -22,10 +22,9 @@ var hmr = new FastHMR(4175696745, "react-context-value-func.tsx", FastRefresh), const ContextProvider = ({ children }) => { const [cb, setCB] = React.useState(function() { }); - const foo = true; return jsx(Context.Provider, { value: cb, - children: children(foo) + children: children(true) }); }; const ContextValue = ({}) => jsx(Context.Consumer, { diff --git a/test/snapshots/react-context-value-func.hmr.tsx b/test/snapshots/react-context-value-func.hmr.tsx index d1473f1c3..8e2b47ab9 100644 --- a/test/snapshots/react-context-value-func.hmr.tsx +++ b/test/snapshots/react-context-value-func.hmr.tsx @@ -22,10 +22,9 @@ var hmr = new FastHMR(4175696745, "react-context-value-func.tsx", FastRefresh), const ContextProvider = ({ children }) => { const [cb, setCB] = React.useState(function() { }); - const foo = true; return jsx(Context.Provider, { value: cb, - children: children(foo) + children: children(true) }); }; const ContextValue = ({}) => jsx(Context.Consumer, { diff --git a/test/snapshots/simple-lit-example.hmr.debug.ts b/test/snapshots/simple-lit-example.hmr.debug.ts index c30111ea3..719c455c2 100644 --- a/test/snapshots/simple-lit-example.hmr.debug.ts +++ b/test/snapshots/simple-lit-example.hmr.debug.ts @@ -67,8 +67,7 @@ var hmr = new HMR(350135693, "simple-lit-example.ts"), exports = hmr.exports; setup(); await loadedPromise; let element = document.getElementById("my-element-id"); - let shadowRoot = element.shadowRoot; - let planet = shadowRoot.getElementById("planet-id"); + let planet = element.shadowRoot.getElementById("planet-id"); if (element.__planet !== "Earth") throw new Error("Unexpected planet name: " + element.__planet); planet.click(); diff --git a/test/snapshots/simple-lit-example.hmr.ts b/test/snapshots/simple-lit-example.hmr.ts index 87c8f6a76..db28dd53e 100644 --- a/test/snapshots/simple-lit-example.hmr.ts +++ b/test/snapshots/simple-lit-example.hmr.ts @@ -67,8 +67,7 @@ var hmr = new HMR(350135693, "simple-lit-example.ts"), exports = hmr.exports; setup(); await loadedPromise; let element = document.getElementById("my-element-id"); - let shadowRoot = element.shadowRoot; - let planet = shadowRoot.getElementById("planet-id"); + let planet = element.shadowRoot.getElementById("planet-id"); if (element.__planet !== "Earth") throw new Error("Unexpected planet name: " + element.__planet); planet.click(); diff --git a/test/snapshots/spread_with_key.hmr.debug.tsx b/test/snapshots/spread_with_key.hmr.debug.tsx index 854343fed..52a655bc9 100644 --- a/test/snapshots/spread_with_key.hmr.debug.tsx +++ b/test/snapshots/spread_with_key.hmr.debug.tsx @@ -20,10 +20,9 @@ var { default: React} = require($a66742df); var hmr = new FastHMR(1094129250, "spread_with_key.tsx", FastRefresh), exports = hmr.exports; (hmr._load = function() { function SpreadWithTheKey({ className }) { - const rest = {}; return jsxEl("div", { className, - ...rest, + ...{}, onClick: () => console.log("click"), key: "spread-with-the-key" }, "Rendered component containing warning"); |