ruby-changes:60576
From: David <ko1@a...>
Date: Mon, 30 Mar 2020 13:01:06 +0900 (JST)
Subject: [ruby-changes:60576] 7e1e60b044 (master): [rubygems/rubygems] Remove ruby 1.8 leftovers
https://git.ruby-lang.org/ruby.git/commit/?id=7e1e60b044 From 7e1e60b0445bc2329e60642e2cc2c14c1668352a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?David=20Rodr=C3=ADguez?= <deivid.rodriguez@r...> Date: Thu, 26 Mar 2020 18:42:48 +0100 Subject: [rubygems/rubygems] Remove ruby 1.8 leftovers https://github.com/rubygems/rubygems/commit/84c89275b8 diff --git a/lib/rubygems/security/policy.rb b/lib/rubygems/security/policy.rb index 1aa6eab..90e40b8 100644 --- a/lib/rubygems/security/policy.rb +++ b/lib/rubygems/security/policy.rb @@ -139,7 +139,7 @@ class Gem::Security::Policy https://github.com/ruby/ruby/blob/trunk/lib/rubygems/security/policy.rb#L139 raise Gem::Security::Exception, "root certificate #{root.subject} is not self-signed " + "(issuer #{root.issuer})" if - root.issuer.to_s != root.subject.to_s # HACK to_s is for ruby 1.8 + root.issuer != root.subject check_cert root, root, time end diff --git a/lib/rubygems/test_case.rb b/lib/rubygems/test_case.rb index ba9b643..3c00a49 100644 --- a/lib/rubygems/test_case.rb +++ b/lib/rubygems/test_case.rb @@ -844,9 +844,7 @@ class Gem::TestCase < (defined?(Minitest::Test) ? Minitest::Test : MiniTest::Uni https://github.com/ruby/ruby/blob/trunk/lib/rubygems/test_case.rb#L844 end if deps - # Since Hash#each is unordered in 1.8, sort the keys and iterate that - # way so the tests are deterministic on all implementations. - deps.keys.sort.each do |n| + deps.keys.each do |n| spec.add_dependency n, (deps[n] || '>= 0') end end @@ -873,10 +871,7 @@ class Gem::TestCase < (defined?(Minitest::Test) ? Minitest::Test : MiniTest::Uni https://github.com/ruby/ruby/blob/trunk/lib/rubygems/test_case.rb#L871 def util_gem(name, version, deps = nil, &block) if deps block = proc do |s| - # Since Hash#each is unordered in 1.8, sort - # the keys and iterate that way so the tests are - # deterministic on all implementations. - deps.keys.sort.each do |n| + deps.keys.each do |n| s.add_dependency n, (deps[n] || '>= 0') end end -- cgit v0.10.2 -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/