diff options
author | 2023-01-20 00:20:33 -0800 | |
---|---|---|
committer | 2023-01-20 00:20:33 -0800 | |
commit | bdf792adbcd146089b309306449bc722f049c32c (patch) | |
tree | 27df4dd31f4bbfd440e81744d52258e9eaca4079 /test/bun.js/transpiler.test.js | |
parent | 3c6616a23ddd885255021217d4c50050417e4e1f (diff) | |
download | bun-bdf792adbcd146089b309306449bc722f049c32c.tar.gz bun-bdf792adbcd146089b309306449bc722f049c32c.tar.zst bun-bdf792adbcd146089b309306449bc722f049c32c.zip |
Add another test
Diffstat (limited to 'test/bun.js/transpiler.test.js')
-rw-r--r-- | test/bun.js/transpiler.test.js | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/test/bun.js/transpiler.test.js b/test/bun.js/transpiler.test.js index a51b49235..413857dae 100644 --- a/test/bun.js/transpiler.test.js +++ b/test/bun.js/transpiler.test.js @@ -128,6 +128,17 @@ class Test extends Bar { for (const [code, out] of fixtures) { expect(ts.parsed(code, false, false).trim()).toBe(out); + expect( + ts + .parsed("var Test = " + code.trim(), false, false) + .trim() + .replaceAll("\n", "") + .replaceAll(" ", ""), + ).toBe( + ("var Test = " + out.trim() + ";\n") + .replaceAll("\n", "") + .replaceAll(" ", ""), + ); } }); |