aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorAlex Lam S.L <alexlamsl@gmail.com>2017-12-20 17:05:40 +0800
committerGitHub <noreply@github.com>2017-12-20 17:05:40 +0800
commit86ae5881b7b269dc656520ff4dddbbd365013a0b (patch)
tree1febf8ed0ae71a44c8c7bd8f104b4776eb4c5aa5 /test
parentfac003c64f5512692e67e41a55b21c74a32a3c6b (diff)
downloadtracifyjs-86ae5881b7b269dc656520ff4dddbbd365013a0b.tar.gz
tracifyjs-86ae5881b7b269dc656520ff4dddbbd365013a0b.zip
disable `hoist_funs` by default (#2626)
Diffstat (limited to 'test')
-rw-r--r--test/mocha/glob.js2
-rw-r--r--test/mocha/minify.js4
2 files changed, 3 insertions, 3 deletions
diff --git a/test/mocha/glob.js b/test/mocha/glob.js
index b6f1e049..58c40cf0 100644
--- a/test/mocha/glob.js
+++ b/test/mocha/glob.js
@@ -11,7 +11,7 @@ describe("bin/uglifyjs with input file globs", function() {
exec(command, function(err, stdout) {
if (err) throw err;
- assert.strictEqual(stdout, 'function foo(o){print("Foo:",2*o)}var print=console.log.bind(console);\n');
+ assert.strictEqual(stdout, 'var print=console.log.bind(console);function foo(o){print("Foo:",2*o)}\n');
done();
});
});
diff --git a/test/mocha/minify.js b/test/mocha/minify.js
index 157d6515..5d9512f3 100644
--- a/test/mocha/minify.js
+++ b/test/mocha/minify.js
@@ -43,7 +43,7 @@ describe("minify", function() {
compressed += result.code;
});
assert.strictEqual(JSON.stringify(cache).slice(0, 20), '{"cname":5,"props":{');
- assert.strictEqual(compressed, 'function n(n){return 3*n}function r(n){return n/2}function c(o){l("Foo:",2*o)}var l=console.log.bind(console);var f=n(3),i=r(12);l("qux",f,i),c(11);');
+ assert.strictEqual(compressed, 'function n(n){return 3*n}function r(n){return n/2}var c=console.log.bind(console);function l(o){c("Foo:",2*o)}var f=n(3),i=r(12);c("qux",f,i),l(11);');
assert.strictEqual(run_code(compressed), run_code(original));
});
@@ -69,7 +69,7 @@ describe("minify", function() {
compressed += result.code;
});
assert.strictEqual(JSON.stringify(cache).slice(0, 28), '{"vars":{"cname":5,"props":{');
- assert.strictEqual(compressed, 'function n(n){return 3*n}function r(n){return n/2}function c(o){l("Foo:",2*o)}var l=console.log.bind(console);var f=n(3),i=r(12);l("qux",f,i),c(11);');
+ assert.strictEqual(compressed, 'function n(n){return 3*n}function r(n){return n/2}var c=console.log.bind(console);function l(o){c("Foo:",2*o)}var f=n(3),i=r(12);c("qux",f,i),l(11);');
assert.strictEqual(run_code(compressed), run_code(original));
});