Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Fix DateTime#to_date is not supported for all rubies

  • Loading branch information...
commit 7ad08efd7fd3e6e2ca2401897135cb950222afcb 1 parent 04a97e1
Markus Schirp authored
Showing with 1 addition and 1 deletion.
  1. +1 −1  spec/integration/timestamps_spec.rb
View
2  spec/integration/timestamps_spec.rb
@@ -8,7 +8,7 @@
it "should not set the created_at/on fields if they're already set" do
green_smoothie = GreenSmoothie.new(:name => 'Banana')
time = (DateTime.now - 100)
- date = time.to_date
+ date = Date.new(time.year,time.month,time.day)
green_smoothie.created_at = time
green_smoothie.created_on = date
green_smoothie.save
Please sign in to comment.
Something went wrong with that request. Please try again.