1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

* lib/rubygems: Update to RubyGems 2.4.1 master(713ab65)

Complete history at:
  https://github.com/rubygems/rubygems/blob/master/History.txt#L3-L216
* test/rubygems:  ditto.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47582 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
hsbt 2014-09-14 03:30:02 +00:00
parent e548c09d42
commit 4de117a615
153 changed files with 5400 additions and 981 deletions

View file

@ -27,6 +27,21 @@ class TestGemSourceGit < Gem::TestCase
assert_path_exists File.join @source.install_dir, 'a.gemspec'
end
def test_checkout_master
Dir.chdir @repository do
system @git, 'checkout', '-q', '-b', 'other'
system @git, 'mv', 'a.gemspec', 'b.gemspec'
system @git, 'commit', '-q', '-a', '-m', 'rename gemspec'
system @git, 'checkout', '-q', 'master'
end
@source = Gem::Source::Git.new @name, @repository, 'other', false
@source.checkout
assert_path_exists File.join @source.install_dir, 'b.gemspec'
end
def test_checkout_local
@source.remote = false
@ -179,14 +194,18 @@ class TestGemSourceGit < Gem::TestCase
git = Gem::Source::Git.new 'a', 'git/a', 'master', false
remote = Gem::Source.new @gem_repo
installed = Gem::Source::Installed.new
vendor = Gem::Source::Vendor.new 'vendor/foo'
assert_equal( 0, git. <=>(git), 'git <=> git')
assert_equal( 1, git. <=>(remote), 'git <=> remote')
assert_equal(-1, remote. <=>(git), 'remote <=> git')
assert_equal( 1, installed.<=>(git), 'installed <=> git')
assert_equal(-1, git. <=>(installed), 'git <=> installed')
assert_equal( 1, git. <=>(installed), 'git <=> installed')
assert_equal(-1, installed.<=>(git), 'installed <=> git')
assert_equal(-1, git. <=>(vendor), 'git <=> vendor')
assert_equal( 1, vendor. <=>(git), 'vendor <=> git')
end
def test_specs
@ -254,6 +273,10 @@ class TestGemSourceGit < Gem::TestCase
end
end
def test_uri
assert_equal URI(@repository), @source.uri
end
def test_uri_hash
assert_equal @hash, @source.uri_hash