fix tests
This commit is contained in:
@@ -5,6 +5,7 @@ class CommentVotesControllerTest < ActionController::TestCase
|
|||||||
setup do
|
setup do
|
||||||
CurrentUser.user = @user = Factory.create(:user)
|
CurrentUser.user = @user = Factory.create(:user)
|
||||||
CurrentUser.ip_addr = "127.0.0.1"
|
CurrentUser.ip_addr = "127.0.0.1"
|
||||||
|
Danbooru.config.stubs(:member_comment_time_threshold).returns(1.week.from_now)
|
||||||
@comment = Factory.create(:comment)
|
@comment = Factory.create(:comment)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
@@ -5,6 +5,7 @@ class CommentsControllerTest < ActionController::TestCase
|
|||||||
setup do
|
setup do
|
||||||
CurrentUser.user = Factory.create(:user)
|
CurrentUser.user = Factory.create(:user)
|
||||||
CurrentUser.ip_addr = "127.0.0.1"
|
CurrentUser.ip_addr = "127.0.0.1"
|
||||||
|
Danbooru.config.stubs(:member_comment_time_threshold).returns(1.week.from_now)
|
||||||
@post = Factory.create(:post)
|
@post = Factory.create(:post)
|
||||||
@comment = Factory.create(:comment, :post => @post)
|
@comment = Factory.create(:comment, :post => @post)
|
||||||
@user = Factory.create(:moderator_user)
|
@user = Factory.create(:moderator_user)
|
||||||
|
|||||||
@@ -7,6 +7,7 @@ module Moderator
|
|||||||
@admin = Factory.create(:admin_user)
|
@admin = Factory.create(:admin_user)
|
||||||
CurrentUser.user = @admin
|
CurrentUser.user = @admin
|
||||||
CurrentUser.ip_addr = "127.0.0.1"
|
CurrentUser.ip_addr = "127.0.0.1"
|
||||||
|
Danbooru.config.stubs(:member_comment_time_threshold).returns(1.week.from_now)
|
||||||
end
|
end
|
||||||
|
|
||||||
context "show action" do
|
context "show action" do
|
||||||
|
|||||||
Reference in New Issue
Block a user