aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authortony <tony>2009-03-16 21:28:09 +0000
committertony <tony>2009-03-16 21:28:09 +0000
commit130f124aad76b87be401aa223ed1de36de784076 (patch)
tree364ae50973b750aa02790f37ceebfea5b60803c3
parent160f6768dcc20f00bec7fdf8d81382dc2cf2ca25 (diff)
Test that Time objects DTRT
-rw-r--r--spec/models/holiday_spec.rb4
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