diff options
author | hsbt <hsbt@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2019-04-02 11:48:18 +0000 |
---|---|---|
committer | hsbt <hsbt@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2019-04-02 11:48:18 +0000 |
commit | f28be7e02d113bd26c33cb94e65004055576c065 (patch) | |
tree | 48b87f5a2b647e1207bae5e29f40d6d5b526978d /test/rubygems/test_gem_commands_setup_command.rb | |
parent | 537024433720d7c54cba9bab4596638f59fbadc9 (diff) |
Merge rubygems/rubygems from upstream.
The current master branch is
https://github.com/rubygems/rubygems/commit/97b264f0fa248c864b6ee9a23d3ff1cdd217dddb
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@67415 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/rubygems/test_gem_commands_setup_command.rb')
-rw-r--r-- | test/rubygems/test_gem_commands_setup_command.rb | 18 |
1 files changed, 11 insertions, 7 deletions
diff --git a/test/rubygems/test_gem_commands_setup_command.rb b/test/rubygems/test_gem_commands_setup_command.rb index 569091a8a7..87ec5c204c 100644 --- a/test/rubygems/test_gem_commands_setup_command.rb +++ b/test/rubygems/test_gem_commands_setup_command.rb @@ -57,6 +57,7 @@ class TestGemCommandsSetupCommand < Gem::TestCase FileUtils.mkdir_p 'default/gems' gemspec = Gem::Specification.new + gemspec.author = "Us" gemspec.name = "bundler" gemspec.version = BUNDLER_VERS gemspec.bindir = "exe" @@ -185,16 +186,19 @@ class TestGemCommandsSetupCommand < Gem::TestCase def test_install_default_bundler_gem @cmd.extend FileUtils - @cmd.install_default_bundler_gem + bin_dir = File.join(@gemhome, 'bin') + @cmd.install_default_bundler_gem bin_dir - if Gem.win_platform? - bundler_spec = Gem::Specification.load("bundler/bundler.gemspec") - default_spec_path = File.join(Gem::Specification.default_specifications_dir, "#{bundler_spec.full_name}.gemspec") - spec = Gem::Specification.load(default_spec_path) + bundler_spec = Gem::Specification.load("bundler/bundler.gemspec") + default_spec_path = File.join(Gem::Specification.default_specifications_dir, "#{bundler_spec.full_name}.gemspec") + spec = Gem::Specification.load(default_spec_path) - spec.executables.each do |e| - assert_path_exists File.join(spec.bin_dir, "#{e}.bat") + spec.executables.each do |e| + if Gem.win_platform? + assert_path_exists File.join(bin_dir, "#{e}.bat") end + + assert_path_exists File.join bin_dir, e end default_dir = Gem::Specification.default_specifications_dir |