Sha256: b427688a9257a662ed9800cb531ca9ae3e3289ea68a337362734616b79e78919
Contents?: true
Size: 565 Bytes
Versions: 2
Compression:
Stored size: 565 Bytes
Contents
# Copyright (c) 2009 Michael Fellinger m.fellinger@gmail.com # All files in this distribution are subject to the terms of the MIT license. require File.expand_path('../../../../lib/ramaze/spec/helper/snippets', __FILE__) describe "Numeric time extensions" do it 'should provide times in the past' do 3.days.ago.to_i.should == (Time.now - 3*24*60*60).to_i 2.months.ago.to_i.should == (Time.now - 2*30*24*60*60).to_i end it 'should provide times in the future' do 2.weeks.from_now.to_i.should == (Time.now + 2*7*24*60*60).to_i end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
ramaze-2012.04.14 | spec/snippets/numeric/time.rb |
ramaze-2012.03.07 | spec/snippets/numeric/time.rb |