Permalink
Browse files

Add spec for :offset option

  • Loading branch information...
1 parent 42dd0f8 commit c5e742e3d80cd44765ab2853c17184072dd6d57b @johnnyshields johnnyshields committed Jan 11, 2014
Showing with 4 additions and 0 deletions.
  1. +4 −0 spec/integration/shared/by_day.rb
@@ -22,6 +22,10 @@
it 'should be able to use an alternative field' do
Event.by_day(:field => 'end_time').count.should eq 4
end
+
+ it 'should support :offset option' do
+ Post.by_day('2014-01-01', :offset => -16.hours).count.should eq 1
+ end
end
describe '#today' do # 2014-01-01

0 comments on commit c5e742e

Please sign in to comment.