Making time_zone_options_for_select return a html_safe string

Signed-off-by: Santiago Pastorino <santiago@wyeworks.com>
This commit is contained in:
Mikel Lindsaar
2010-08-15 22:36:29 +10:00
committed by Santiago Pastorino
parent 1607a8b08c
commit fd9f3ad36b
2 changed files with 5 additions and 1 deletions

View File

@@ -493,7 +493,7 @@ module ActionView
end
zone_options += options_for_select(convert_zones[zones], selected)
zone_options
zone_options.html_safe
end
private

View File

@@ -289,6 +289,10 @@ class FormOptionsHelperTest < ActionView::TestCase
opts
end
def test_time_zone_options_returns_html_safe_string
assert time_zone_options_for_select.html_safe?
end
def test_select
@post = Post.new
@post.category = "<mus>"