Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 0 additions & 8 deletions bundler/spec/commands/clean_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -913,12 +913,10 @@ def should_not_have_gems(*gems)
# Simulate that the locked bundler version is installed in the bundle path
# by creating the gem directory and gemspec (as would happen after bundle install with that version)
Pathname(vendored_gems("cache/bundler-#{version}.gem")).tap do |path|
path.basename.mkpath
FileUtils.touch(path)
end
FileUtils.touch(vendored_gems("gems/bundler-#{version}"))
Pathname(vendored_gems("specifications/bundler-#{version}.gemspec")).tap do |path|
path.basename.mkpath
path.write(<<~GEMSPEC)
Gem::Specification.new do |s|
s.name = "bundler"
Expand All @@ -934,11 +932,5 @@ def should_not_have_gems(*gems)
bundle :clean

should_have_gems "bundler-#{version}"
ensure
["bundler-#{version}.gem", "bundler-#{version}.gemspec"].each do |filename|
Pathname(vendored_gems(filename)).tap do |path|
FileUtils.rm_rf(path.basename)
end
end
end
end