fix tests, fixes #1173
This commit is contained in:
@@ -23,7 +23,7 @@ class CommentTest < ActiveSupport::TestCase
|
||||
should "fail creation" do
|
||||
comment = FactoryGirl.build(:comment)
|
||||
comment.save
|
||||
assert_equal(["Creator can not post comments within 1 week of sign up, and can only post 5 comments per hour after that"], comment.errors.full_messages)
|
||||
assert_equal(["You can not post comments within 1 week of sign up"], comment.errors.full_messages)
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
@@ -81,10 +81,11 @@ class UserTest < ActiveSupport::TestCase
|
||||
@user.update_column(:level, User::Levels::MEMBER)
|
||||
@user.update_column(:created_at, 1.year.ago)
|
||||
assert(@user.can_comment?)
|
||||
assert(!@user.is_comment_limited?)
|
||||
(Danbooru.config.member_comment_limit).times do
|
||||
FactoryGirl.create(:comment)
|
||||
end
|
||||
assert(!@user.can_comment?)
|
||||
assert(@user.is_comment_limited?)
|
||||
end
|
||||
|
||||
should "verify" do
|
||||
|
||||
Reference in New Issue
Block a user