What is the best way to generate a random DateTime in Ruby/Rails? Trying to create a nice seeds.rb file. Going to use it like so:
Foo.create(name: Faker::Lo
Here is how to create a date in this month:
day = 1.times.map{ 0+Random.rand(30) }.join.to_i rand(day.days).ago