зеркало из https://github.com/github/ruby.git
* lib/rubygems/installer.rb: Fixed placement of executables with
--user-install. [ruby-trunk - Bug #7779] * test/rubygems/test_gem_installer.rb: Test for above. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@39307 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
Родитель
10103e8cc7
Коммит
aec0735f6d
|
@ -1,3 +1,9 @@
|
|||
Tue Feb 19 08:14:40 2013 Eric Hodel <drbrain@segment7.net>
|
||||
|
||||
* lib/rubygems/installer.rb: Fixed placement of executables with
|
||||
--user-install. [ruby-trunk - Bug #7779]
|
||||
* test/rubygems/test_gem_installer.rb: Test for above.
|
||||
|
||||
Tue Feb 19 06:04:06 2013 NARUSE, Yui <naruse@ruby-lang.org>
|
||||
|
||||
* vm_dump: FreeBSD ports' libexecinfo's backtrace(3) can't trace
|
||||
|
|
|
@ -110,6 +110,7 @@ class Gem::Installer
|
|||
|
||||
if options[:user_install] and not options[:unpack] then
|
||||
@gem_home = Gem.user_dir
|
||||
@bin_dir = Gem.bindir gem_home unless options[:bin_dir]
|
||||
check_that_user_bin_dir_is_in_path
|
||||
end
|
||||
end
|
||||
|
|
|
@ -661,6 +661,24 @@ load Gem.bin_path('a', 'executable', version)
|
|||
installer = Gem::Installer.new gem
|
||||
|
||||
assert_equal File.join(@gemhome, 'gems', spec.full_name), installer.gem_dir
|
||||
assert_equal File.join(@gemhome, 'bin'), installer.bin_dir
|
||||
end
|
||||
|
||||
def test_initialize_user_install
|
||||
installer = Gem::Installer.new @gem, :user_install => true
|
||||
|
||||
assert_equal File.join(Gem.user_dir, 'gems', @spec.full_name),
|
||||
installer.gem_dir
|
||||
assert_equal Gem.bindir(Gem.user_dir), installer.bin_dir
|
||||
end
|
||||
|
||||
def test_initialize_user_install_bin_dir
|
||||
installer =
|
||||
Gem::Installer.new @gem, :user_install => true, :bin_dir => @tempdir
|
||||
|
||||
assert_equal File.join(Gem.user_dir, 'gems', @spec.full_name),
|
||||
installer.gem_dir
|
||||
assert_equal @tempdir, installer.bin_dir
|
||||
end
|
||||
|
||||
def test_install
|
||||
|
|
Загрузка…
Ссылка в новой задаче