aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Rakefile2
-rw-r--r--lib/bundler/spec_set.rb2
-rw-r--r--spec/install/gems/resolving_spec.rb20
3 files changed, 23 insertions, 1 deletions
diff --git a/Rakefile b/Rakefile
index dd134363..a7126e62 100644
--- a/Rakefile
+++ b/Rakefile
@@ -17,6 +17,8 @@ spec = Gem::Specification.new do |s|
s.required_rubygems_version = ">= 1.3.6"
+ s.add_development_dependency "rspec"
+
s.files = Dir.glob("{bin,lib}/**/*") + %w(LICENSE README.md ROADMAP.md CHANGELOG.md)
s.executables = ['bundle']
s.require_path = 'lib'
diff --git a/lib/bundler/spec_set.rb b/lib/bundler/spec_set.rb
index 16764cd7..c0257242 100644
--- a/lib/bundler/spec_set.rb
+++ b/lib/bundler/spec_set.rb
@@ -36,7 +36,7 @@ module Bundler
return if specs[current.name]
specs[current.name] = true
current.dependencies.each do |dep|
- next unless dep.type == :runtime
+ next if dep.type == :development
append_subgraph(specs, lookup[dep.name])
end
end
diff --git a/spec/install/gems/resolving_spec.rb b/spec/install/gems/resolving_spec.rb
index 72f70e9d..a7983e94 100644
--- a/spec/install/gems/resolving_spec.rb
+++ b/spec/install/gems/resolving_spec.rb
@@ -19,6 +19,26 @@ describe "bundle install with gem sources" do
out.should == "YES\nYES"
end
+ it "installs gems with a dependency with no type" do
+ build_repo2
+
+ path = "#{gem_repo2}/#{Gem::MARSHAL_SPEC_DIR}/actionpack-2.3.2.gemspec.rz"
+ spec = Marshal.load(Gem.inflate(File.read(path)))
+ spec.dependencies.each do |d|
+ d.instance_variable_set(:@type, :fail)
+ end
+ File.open(path, 'w') do |f|
+ f.write Gem.deflate(Marshal.dump(spec))
+ end
+
+ install_gemfile <<-G
+ source "file://#{gem_repo2}"
+ gem "actionpack", "2.3.2"
+ G
+
+ should_be_installed "actionpack 2.3.2", "activesupport 2.3.2"
+ end
+
it "works with crazy rubygem plugin stuff" do
install_gemfile <<-G
source "file://#{gem_repo1}"