You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
trustieforge/lib/rack-mini-profiler/spec/spec_helper.rb

32 lines
488 B

Dir[File.dirname(__FILE__) + "/support/**/*.rb"].each {|f| require f}
RSpec.configure do |config|
config.color_enabled = true
end
class Time
class << self
unless method_defined? :old_new
alias_method :old_new, :new
alias_method :old_now, :now
def new
@now || old_new
end
def now
@now || old_now
end
def now=(v)
@now = v
end
def back_to_normal
@now = nil
end
end
end
end