mirror of
https://github.com/discourse/discourse.git
synced 2025-06-05 14:07:30 +08:00
refactor validators
add a new setting for min pm body length use that setting for flags scale entropy check down for pms
This commit is contained in:
@ -365,8 +365,14 @@ describe Post do
|
||||
|
||||
end
|
||||
|
||||
it 'validates' do
|
||||
Fabricate.build(:post, post_args).should be_valid
|
||||
context 'validation' do
|
||||
it 'validates our default post' do
|
||||
Fabricate.build(:post, post_args).should be_valid
|
||||
end
|
||||
|
||||
it 'treate blank posts as invalid' do
|
||||
Fabricate.build(:post, raw: "").should_not be_valid
|
||||
end
|
||||
end
|
||||
|
||||
context "raw_hash" do
|
||||
|
Reference in New Issue
Block a user