fix post test
This commit is contained in:
@@ -1,6 +1,10 @@
|
|||||||
module Mentionable
|
module Mentionable
|
||||||
extend ActiveSupport::Concern
|
extend ActiveSupport::Concern
|
||||||
|
|
||||||
|
included do
|
||||||
|
attr_accessor :skip_mention_notifications
|
||||||
|
end
|
||||||
|
|
||||||
module ClassMethods
|
module ClassMethods
|
||||||
# options:
|
# options:
|
||||||
# - message_field
|
# - message_field
|
||||||
|
|||||||
@@ -3,7 +3,6 @@ class ForumPost < ApplicationRecord
|
|||||||
|
|
||||||
attr_accessible :body, :topic_id, :as => [:member, :builder, :gold, :platinum, :admin, :moderator, :default]
|
attr_accessible :body, :topic_id, :as => [:member, :builder, :gold, :platinum, :admin, :moderator, :default]
|
||||||
attr_accessible :is_locked, :is_sticky, :is_deleted, :as => [:admin, :moderator]
|
attr_accessible :is_locked, :is_sticky, :is_deleted, :as => [:admin, :moderator]
|
||||||
attr_accessor :skip_mention_notifications # used by `Mentionable::queue_mention_messages`
|
|
||||||
attr_readonly :topic_id
|
attr_readonly :topic_id
|
||||||
belongs_to :creator, :class_name => "User"
|
belongs_to :creator, :class_name => "User"
|
||||||
belongs_to :updater, :class_name => "User"
|
belongs_to :updater, :class_name => "User"
|
||||||
|
|||||||
@@ -21,6 +21,7 @@ class PostTest < ActiveSupport::TestCase
|
|||||||
CurrentUser.user = @user
|
CurrentUser.user = @user
|
||||||
CurrentUser.ip_addr = "127.0.0.1"
|
CurrentUser.ip_addr = "127.0.0.1"
|
||||||
mock_saved_search_service!
|
mock_saved_search_service!
|
||||||
|
mock_pool_archive_service!
|
||||||
ImageCropper.stubs(:enabled?).returns(false)
|
ImageCropper.stubs(:enabled?).returns(false)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user