diff options
author | tony <tony> | 2009-03-16 21:28:09 +0000 |
---|---|---|
committer | tony <tony> | 2009-03-16 21:28:09 +0000 |
commit | 130f124aad76b87be401aa223ed1de36de784076 (patch) | |
tree | 364ae50973b750aa02790f37ceebfea5b60803c3 | |
parent | 160f6768dcc20f00bec7fdf8d81382dc2cf2ca25 (diff) |
Test that Time objects DTRT
-rw-r--r-- | spec/models/holiday_spec.rb | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/spec/models/holiday_spec.rb b/spec/models/holiday_spec.rb index f4dfc7476..6179bb434 100644 --- a/spec/models/holiday_spec.rb +++ b/spec/models/holiday_spec.rb @@ -39,5 +39,9 @@ describe Holiday, " when calculating due date" do due_date('2009-03-16').should == '2009-04-16' end + it "handles Time objects" do + Holiday.due_date_from(Time.utc(2009, 03, 16, 12, 0, 0)).strftime('%F').should == '2009-04-16' + end + end |