test for errors messages with HTML tags
This commit is contained in:
parent
312796b1ee
commit
18b73ddba4
|
@ -73,6 +73,12 @@ class ErrorTest < ActionView::TestCase
|
||||||
assert_no_select 'p.error[error_method]'
|
assert_no_select 'p.error[error_method]'
|
||||||
end
|
end
|
||||||
|
|
||||||
|
test 'error should generate an error message with raw HTML tags' do
|
||||||
|
with_error_for @user, :name, :error_prefix => '<b>Name</b>'
|
||||||
|
assert_select 'span.error', "Name can't be blank"
|
||||||
|
assert_select 'span.error b', "Name"
|
||||||
|
end
|
||||||
|
|
||||||
# FULL ERRORS
|
# FULL ERRORS
|
||||||
|
|
||||||
test 'full error should generate an full error tag for the attribute' do
|
test 'full error should generate an full error tag for the attribute' do
|
||||||
|
|
Loading…
Reference in New Issue