mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
3908d5d330
* test/rake: ditto. * NEWS: ditto. * test/lib/minitest/unit.rb: Add compatibility shim for minitest 5. This only provides minitest 5 unit test naming compatibility. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48560 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
16 lines
367 B
Ruby
16 lines
367 B
Ruby
#--
|
|
# Extensions to time to allow comparisons with early and late time classes.
|
|
|
|
require 'rake/early_time'
|
|
require 'rake/late_time'
|
|
|
|
class Time # :nodoc: all
|
|
alias rake_original_time_compare :<=>
|
|
def <=>(other)
|
|
if Rake::EarlyTime === other || Rake::LateTime === other
|
|
- other.<=>(self)
|
|
else
|
|
rake_original_time_compare(other)
|
|
end
|
|
end
|
|
end
|