Skip to content

Commit

Permalink
Update UglifyJS to 2.4.23
Browse files Browse the repository at this point in the history
  • Loading branch information
lautis committed Aug 26, 2015
1 parent f6e43e8 commit 887648d
Show file tree
Hide file tree
Showing 3 changed files with 63 additions and 14 deletions.
60 changes: 50 additions & 10 deletions lib/uglify.js

Large diffs are not rendered by default.

15 changes: 12 additions & 3 deletions spec/uglifier_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -230,10 +230,19 @@
function plus(a, b, c) { return a + b};
plus(1, 2);
EOF
expect(Uglifier.compile(code, :mangle => false)).not_to include("c)")

keep_fargs = Uglifier.compile(code, :mangle => false, :compress => { :keep_fargs => true })
expect(keep_fargs).to include("c)")
options = lambda do |keep_fargs|
{
:mangle => false,
:compress => {
:keep_fargs => keep_fargs,
:unsafe => true
}
}
end

expect(Uglifier.compile(code, options.call(false))).not_to include("c)")
expect(Uglifier.compile(code, options.call(true))).to include("c)")
end

describe "Input Formats" do
Expand Down
2 changes: 1 addition & 1 deletion vendor/uglifyjs

0 comments on commit 887648d

Please sign in to comment.