aboutsummaryrefslogtreecommitdiffstats
path: root/spec/models/censor_rule_spec.rb
diff options
context:
space:
mode:
Diffstat (limited to 'spec/models/censor_rule_spec.rb')
-rw-r--r--spec/models/censor_rule_spec.rb6
1 files changed, 6 insertions, 0 deletions
diff --git a/spec/models/censor_rule_spec.rb b/spec/models/censor_rule_spec.rb
index 471a73fa2..1965b0894 100644
--- a/spec/models/censor_rule_spec.rb
+++ b/spec/models/censor_rule_spec.rb
@@ -73,6 +73,12 @@ end
describe 'when validating rules' do
+ describe 'should be invalid without text' do
+ censor_rule = CensorRule.new
+ censor_rule.valid?.should == false
+ censor_rule.errors.on(:text).should == "can't be blank"
+ end
+
describe 'when validating a regexp rule' do
before do