Fix report_spec so it's not so fussy and breaks sometimes

This commit is contained in:
Neil Lalonde 2013-03-11 10:40:13 -04:00
parent b554bf4520
commit f1908fd8e8

View File

@ -102,10 +102,7 @@ describe Report do
it 'should cache the data set' do
$redis.expects(:setex).with do |key, expiry, string|
key == 'signups:data' and
expiry == Report.cache_expiry # and
string.include? "#{1.days.ago.to_date.to_s},1" and
string.include? "#{0.days.ago.to_date.to_s},2"
string =~ /(\d)+-(\d)+-(\d)+,1/ and string =~ /(\d)+-(\d)+-(\d)+,2/
end
report()
end