mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
Merge RubyGems master@9be7858f7f17eae3058204f3c03e4b798ba18b9c
This version contains the some style changes by RuboCop.
* 9d810be0ed
* 61ea98a727
* 795893dce3
* 9be7858f7f
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@67074 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
d1e6304a89
commit
4ae3df42f7
160 changed files with 1159 additions and 578 deletions
|
|
@ -40,25 +40,25 @@ class TestGemSourceLock < Gem::TestCase
|
|||
vendor = Gem::Source::Vendor.new 'vendor/a'
|
||||
v_lock = Gem::Source::Lock.new vendor
|
||||
|
||||
assert_equal( 0, g_lock.<=>(g_lock), 'g_lock <=> g_lock')
|
||||
assert_equal( 0, i_lock.<=>(i_lock), 'i_lock <=> i_lock')
|
||||
assert_equal( 0, v_lock.<=>(v_lock), 'v_lock <=> v_lock')
|
||||
assert_equal(0, g_lock.<=>(g_lock), 'g_lock <=> g_lock')
|
||||
assert_equal(0, i_lock.<=>(i_lock), 'i_lock <=> i_lock')
|
||||
assert_equal(0, v_lock.<=>(v_lock), 'v_lock <=> v_lock')
|
||||
|
||||
assert_equal( 1, g_lock.<=>(i_lock), 'g_lock <=> i_lock')
|
||||
assert_equal(1, g_lock.<=>(i_lock), 'g_lock <=> i_lock')
|
||||
assert_equal(-1, i_lock.<=>(g_lock), 'i_lock <=> g_lock')
|
||||
|
||||
assert_equal(-1, g_lock.<=>(v_lock), 'g_lock <=> v_lock')
|
||||
assert_equal( 1, v_lock.<=>(g_lock), 'v_lock <=> g_lock')
|
||||
assert_equal(1, v_lock.<=>(g_lock), 'v_lock <=> g_lock')
|
||||
|
||||
assert_equal(-1, i_lock.<=>(v_lock), 'i_lock <=> v_lock')
|
||||
assert_equal( 1, v_lock.<=>(i_lock), 'i_lock <=> v_lock')
|
||||
assert_equal(1, v_lock.<=>(i_lock), 'i_lock <=> v_lock')
|
||||
end
|
||||
|
||||
def test_spaceship_git
|
||||
git = Gem::Source::Git.new 'a', 'git/a', 'master', false
|
||||
lock = Gem::Source::Lock.new git
|
||||
|
||||
assert_equal( 1, lock.<=>(git), 'lock <=> git')
|
||||
assert_equal(1, lock.<=>(git), 'lock <=> git')
|
||||
assert_equal(-1, git .<=>(lock), 'git <=> lock')
|
||||
end
|
||||
|
||||
|
|
@ -66,7 +66,7 @@ class TestGemSourceLock < Gem::TestCase
|
|||
installed = Gem::Source::Installed.new
|
||||
lock = Gem::Source::Lock.new installed
|
||||
|
||||
assert_equal( 1, lock. <=>(installed), 'lock <=> installed')
|
||||
assert_equal(1, lock. <=>(installed), 'lock <=> installed')
|
||||
assert_equal(-1, installed.<=>(lock), 'installed <=> lock')
|
||||
end
|
||||
|
||||
|
|
@ -74,7 +74,7 @@ class TestGemSourceLock < Gem::TestCase
|
|||
local = Gem::Source::Local.new
|
||||
lock = Gem::Source::Lock.new local # nonsense
|
||||
|
||||
assert_equal( 1, lock. <=>(local), 'lock <=> local')
|
||||
assert_equal(1, lock. <=>(local), 'lock <=> local')
|
||||
assert_equal(-1, local.<=>(lock), 'local <=> lock')
|
||||
end
|
||||
|
||||
|
|
@ -82,7 +82,7 @@ class TestGemSourceLock < Gem::TestCase
|
|||
remote = Gem::Source.new @gem_repo
|
||||
lock = Gem::Source::Lock.new remote
|
||||
|
||||
assert_equal( 1, lock. <=>(remote), 'lock <=> remote')
|
||||
assert_equal(1, lock. <=>(remote), 'lock <=> remote')
|
||||
assert_equal(-1, remote.<=>(lock), 'remote <=> lock')
|
||||
end
|
||||
|
||||
|
|
@ -92,7 +92,7 @@ class TestGemSourceLock < Gem::TestCase
|
|||
specific = Gem::Source::SpecificFile.new gem
|
||||
lock = Gem::Source::Lock.new specific # nonsense
|
||||
|
||||
assert_equal( 1, lock .<=>(specific), 'lock <=> specific')
|
||||
assert_equal(1, lock .<=>(specific), 'lock <=> specific')
|
||||
assert_equal(-1, specific.<=>(lock), 'specific <=> lock')
|
||||
end
|
||||
|
||||
|
|
@ -100,7 +100,7 @@ class TestGemSourceLock < Gem::TestCase
|
|||
vendor = Gem::Source::Vendor.new 'vendor/a'
|
||||
lock = Gem::Source::Lock.new vendor
|
||||
|
||||
assert_equal( 1, lock. <=>(vendor), 'lock <=> vendor')
|
||||
assert_equal(1, lock. <=>(vendor), 'lock <=> vendor')
|
||||
assert_equal(-1, vendor.<=>(lock), 'vendor <=> lock')
|
||||
end
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue