From bf6b846c0baece208df778cfda3d46aa611aeffb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9gis=20Hanol?= Date: Fri, 31 May 2013 17:51:22 +0200 Subject: [PATCH] Fix upload specs --- spec/models/upload_spec.rb | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/spec/models/upload_spec.rb b/spec/models/upload_spec.rb index 2c4e8dbaaba..8d214864a19 100644 --- a/spec/models/upload_spec.rb +++ b/spec/models/upload_spec.rb @@ -102,17 +102,14 @@ describe Upload do let(:upload) do # The Time needs to be frozen as it is used to generate a clean & unique name - Timecop.freeze(Time.new(2013, 2, 17, 0, 0, 0)) do - Upload.create_locally(user_id, logo, topic_id) - end + Time.stubs(:now).returns(Time.utc(2013, 2, 17, 12, 0, 0, 0)) + Upload.create_locally(user_id, logo, topic_id) end it_behaves_like "upload" it "works" do - pending "zogstrip can you have a look at this, hash is different" do - upload.url.should match /\/uploads\/default\/[\d]+\/efaf7c3915fdfd3b.png/ - end + upload.url.should match /\/uploads\/default\/[\d]+\/253dc8edf9d4ada1.png/ end end