summaryrefslogtreecommitdiff
path: root/test/rubygems/test_gem_commands_setup_command.rb
diff options
context:
space:
mode:
authorDavid Rodríguez <[email protected]>2022-07-16 13:31:24 +0200
committergit <[email protected]>2022-07-20 19:55:33 +0900
commitbdef3c73fe3792de59ecf681d2dcfcc8f62422b1 ()
treea74ec6c9f0712286d5db9c592e98a24d833a621a /test/rubygems/test_gem_commands_setup_command.rb
parentcbaf58d45564c17135595b549d4a0369f0e5a008 (diff)
[rubygems/rubygems] Unify common logic
https://.com/rubygems/rubygems/commit/e5434be14c
-rw-r--r--test/rubygems/test_gem_commands_setup_command.rb20
1 files changed, 12 insertions, 8 deletions
@@ -211,11 +211,9 @@ class TestGemCommandsSetupCommand < Gem::TestCase
assert_path_exist File.join bin_dir, e
end
- default_dir = Gem.default_specifications_dir
-
# expect to remove other versions of bundler gemspecs on default specification directory.
- assert_path_not_exist File.join(default_dir, "bundler-1.15.4.gemspec")
- assert_path_exist File.join(default_dir, "bundler-#{BUNDLER_VERS}.gemspec")
# expect to not remove bundler-* gemspecs.
assert_path_exist File.join(Gem.dir, "specifications", "bundler-audit-1.0.0.gemspec")
@@ -239,11 +237,9 @@ class TestGemCommandsSetupCommand < Gem::TestCase
@cmd.install_default_bundler_gem bin_dir
- default_dir = Gem.default_specifications_dir
-
# expect to remove other versions of bundler gemspecs on default specification directory.
- assert_path_not_exist File.join(default_dir, "bundler-1.15.4.gemspec")
- assert_path_exist File.join(default_dir, "bundler-#{BUNDLER_VERS}.gemspec")
end
def test_install_default_bundler_gem_with_force_flag
@@ -462,4 +458,12 @@ class TestGemCommandsSetupCommand < Gem::TestCase
def default_bundler_bin_path
File.join RbConfig::CONFIG['bindir'], 'bundler'
end
end unless Gem.java_platform?