fix forum post test
This commit is contained in:
@@ -36,7 +36,7 @@ class Cache
|
||||
value = MEMCACHE.get key
|
||||
elapsed = Time.now - start_time
|
||||
if expiry_in_seconds
|
||||
expiry = expiry_in_seconds.seconds.from_now.to_i if expiry_in_seconds
|
||||
expiry = expiry_in_seconds.seconds.from_now.to_i
|
||||
else
|
||||
expiry = 0
|
||||
end
|
||||
|
||||
@@ -27,6 +27,10 @@ class ForumPostTest < ActiveSupport::TestCase
|
||||
end
|
||||
|
||||
context "that is deleted" do
|
||||
setup do
|
||||
CurrentUser.user = FactoryGirl.create(:moderator_user)
|
||||
end
|
||||
|
||||
should "update the topic's updated_at timestamp" do
|
||||
@topic.reload
|
||||
assert_equal(@posts[-1].updated_at.to_i, @topic.updated_at.to_i)
|
||||
|
||||
Reference in New Issue
Block a user