diff options
author | Bartek IwaĆczuk <biwanczuk@gmail.com> | 2021-01-11 15:32:34 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-01-11 15:32:34 +0100 |
commit | d676b6c63ada85801673f0e691f8ba11e44e347a (patch) | |
tree | 02067230de7802bfe166139a88324dda596c6dc1 /cli/tests | |
parent | 2b75a1155906613df16bad9d1eb84f3dc0ba571b (diff) |
upgrade: swc_bundler 0.19.2 (#9085)
Diffstat (limited to 'cli/tests')
-rw-r--r-- | cli/tests/bundle.test.out | 26 | ||||
-rw-r--r-- | cli/tests/bundle/fixture02.out | 5 | ||||
-rw-r--r-- | cli/tests/bundle/fixture08.out | 2 | ||||
-rw-r--r-- | cli/tests/bundle/fixture09.out | 5 | ||||
-rw-r--r-- | cli/tests/bundle/fixture10.out | 2 | ||||
-rw-r--r-- | cli/tests/bundle/fixture11.out | 7 | ||||
-rw-r--r-- | cli/tests/bundle/fixture14.out | 18 | ||||
-rw-r--r-- | cli/tests/bundle/fixture15.out | 4 |
8 files changed, 41 insertions, 28 deletions
diff --git a/cli/tests/bundle.test.out b/cli/tests/bundle.test.out index d90dc9f95..155430c99 100644 --- a/cli/tests/bundle.test.out +++ b/cli/tests/bundle.test.out @@ -1,23 +1,31 @@ [WILDCARD] -function printHello() { - console.log("Hello"); +function returnsHi() { + return "Hi"; } function returnsFoo() { return "Foo"; } +function printHello() { + console.log("Hello"); +} function printHello2() { printHello(); } -export function returnsHi() { - return "Hi"; -} -export function returnsFoo2() { +function returnsFoo2() { return returnsFoo(); } -export function printHello3() { +function printHello3() { printHello2(); } -export function throwsError() { +function throwsError() { throw Error("exception from mod1"); } -[WILDCARD]
\ No newline at end of file +const returnsHi1 = returnsHi; +const returnsFoo21 = returnsFoo2; +const printHello31 = printHello3; +const throwsError1 = throwsError; +export { returnsHi as returnsHi }; +export { returnsFoo2 as returnsFoo2 }; +export { printHello3 as printHello3 }; +export { throwsError as throwsError }; + diff --git a/cli/tests/bundle/fixture02.out b/cli/tests/bundle/fixture02.out index aad359fce..b14fc143b 100644 --- a/cli/tests/bundle/fixture02.out +++ b/cli/tests/bundle/fixture02.out @@ -4,10 +4,11 @@ const mod = function() { const c = "c"; class C { } - const __default = C; const c1 = c; + const __default = C; + const __default1 = C; return { - c, + c: c, default: C }; }(); diff --git a/cli/tests/bundle/fixture08.out b/cli/tests/bundle/fixture08.out index 01d6befb4..0ab646840 100644 --- a/cli/tests/bundle/fixture08.out +++ b/cli/tests/bundle/fixture08.out @@ -2,7 +2,7 @@ const mod = function() { const a = "a"; const a1 = a; return { - a + a: a }; }(); const a = mod; diff --git a/cli/tests/bundle/fixture09.out b/cli/tests/bundle/fixture09.out index e7396f493..73031ef02 100644 --- a/cli/tests/bundle/fixture09.out +++ b/cli/tests/bundle/fixture09.out @@ -15,6 +15,7 @@ const mod1 = function() { }; }(); const k = globalThis.value ? mod : mod1; -const { a: a2 , } = k; -const a1 = a2; +const { a , } = k; +const a1 = a; +const a2 = a; export { a1 as a }; diff --git a/cli/tests/bundle/fixture10.out b/cli/tests/bundle/fixture10.out index 5491e5e7f..209c19612 100644 --- a/cli/tests/bundle/fixture10.out +++ b/cli/tests/bundle/fixture10.out @@ -1,5 +1,5 @@ -const a = "a"; const o = { }; +const a = "a"; const { a: a1 = a } = o; console.log(a1); diff --git a/cli/tests/bundle/fixture11.out b/cli/tests/bundle/fixture11.out index 3dc1a454b..9c22c3b09 100644 --- a/cli/tests/bundle/fixture11.out +++ b/cli/tests/bundle/fixture11.out @@ -1,6 +1,3 @@ -function a() { - console.log("a"); -} var O2; (function(O1) { O1[O1["A"] = 0] = "A"; @@ -8,6 +5,9 @@ var O2; O1[O1["C"] = 2] = "C"; })(O2 || (O2 = { })); +function a() { + console.log("a"); +} const O1 = O2; export { O1 as O }; class A { @@ -29,3 +29,4 @@ class A { const a2 = new A(); a2.a(); a2.c(); +const O3 = O2; diff --git a/cli/tests/bundle/fixture14.out b/cli/tests/bundle/fixture14.out index 80532a1dd..2534a7015 100644 --- a/cli/tests/bundle/fixture14.out +++ b/cli/tests/bundle/fixture14.out @@ -6,26 +6,26 @@ const mod = function() { }(); console.log(mod); const mod1 = function() { - const a = []; - const a1 = a; + const c = []; + const c1 = c; return { - a + c: c }; }(); -const a = mod1; +const c = mod1; const mod2 = function() { const b = []; const b1 = b; return { - b + b: b }; }(); const b = mod2; const mod3 = function() { - const c = []; - const c1 = c; + const a = []; + const a1 = a; return { - c + a: a }; }(); -const c = mod3; +const a = mod3; diff --git a/cli/tests/bundle/fixture15.out b/cli/tests/bundle/fixture15.out index b8e7cfc5e..408d8464f 100644 --- a/cli/tests/bundle/fixture15.out +++ b/cli/tests/bundle/fixture15.out @@ -1,3 +1,5 @@ -export function getIndex(c) { +function getIndex(c) { return "\x00\r\n\x85\u2028\u2029".indexOf(c); } +const getIndex1 = getIndex; +export { getIndex as getIndex }; |