Compare dates with to_i (trying to fix a Travis failure)