aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/mocha/cli.js9
1 files changed, 9 insertions, 0 deletions
diff --git a/test/mocha/cli.js b/test/mocha/cli.js
index 565b6069..4234f2fb 100644
--- a/test/mocha/cli.js
+++ b/test/mocha/cli.js
@@ -537,4 +537,13 @@ describe("bin/uglifyjs", function () {
done();
});
});
+ it("Should print supported options on invalid option syntax", function(done) {
+ var command = uglifyjscmd + " test/input/comments/filter.js -b ascii-only";
+ exec(command, function (err, stdout, stderr) {
+ assert.ok(err);
+ assert.strictEqual(stdout, "");
+ assert.ok(/^Supported options:\n\{[^}]+}\nERROR: `ascii-only` is not a supported option/.test(stderr), stderr);
+ done();
+ });
+ });
});