Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Respect the gemfile :groups option

  • Loading branch information...
commit ecedf7a17b075addd5de5c0831fbd811a4b8c800 1 parent 368ad2c
@laserlemon laserlemon authored
View
1  lib/gemnasium/parser/gemfile.rb
@@ -94,6 +94,7 @@ def path_matches
end
def clean!(match, opts)
+ opts["group"] ||= opts.delete("groups")
opts["group"] ||= groups(match)
groups = Array(opts["group"]).flatten.compact
runtime = groups.empty? || !(groups & Parser.runtime_groups).empty?
View
5 spec/gemnasium/parser/gemfile_spec.rb
@@ -112,6 +112,11 @@ def reset
dependency.groups.should == [:development, :test]
end
+ it "recognizes :groups" do
+ content(%(gem "rake", :groups => [:development, :test]))
+ dependency.groups.should == [:development, :test]
+ end
+
it "parses gems in a group" do
content(<<-EOF)
gem "rake"
Please sign in to comment.
Something went wrong with that request. Please try again.