aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/test/template
diff options
context:
space:
mode:
authorJosé Valim <jose.valim@gmail.com>2010-05-15 09:08:40 +0200
committerJosé Valim <jose.valim@gmail.com>2010-05-15 09:08:40 +0200
commitd18a2742e01d195eb2d228207062aff49f7eb854 (patch)
treebda97721b4410a221bd3405a440931f6f2de1869 /actionpack/test/template
parent6e69b42b21d8e76c4d87b6fbc4222f55d3b11a06 (diff)
downloadrails-d18a2742e01d195eb2d228207062aff49f7eb854.tar.gz
rails-d18a2742e01d195eb2d228207062aff49f7eb854.tar.bz2
rails-d18a2742e01d195eb2d228207062aff49f7eb854.zip
Improve previous patch a bit [#3645 state:resolved]
Diffstat (limited to 'actionpack/test/template')
-rw-r--r--actionpack/test/template/form_tag_helper_test.rb5
1 files changed, 5 insertions, 0 deletions
diff --git a/actionpack/test/template/form_tag_helper_test.rb b/actionpack/test/template/form_tag_helper_test.rb
index 1e116c041f..1c095b621e 100644
--- a/actionpack/test/template/form_tag_helper_test.rb
+++ b/actionpack/test/template/form_tag_helper_test.rb
@@ -297,6 +297,11 @@ class FormTagHelperTest < ActionView::TestCase
assert_dom_equal('<label for="clock">Grandfather</label>', output)
end
+ def test_label_tag_with_block_and_argument_and_options
+ output = label_tag("clock", :id => "label_clock") { "Grandfather" }
+ assert_dom_equal('<label for="clock" id="label_clock">Grandfather</label>', output)
+ end
+
def test_boolean_options
assert_dom_equal %(<input checked="checked" disabled="disabled" id="admin" name="admin" readonly="readonly" type="checkbox" value="1" />), check_box_tag("admin", 1, true, 'disabled' => true, :readonly => "yes")
assert_dom_equal %(<input checked="checked" id="admin" name="admin" type="checkbox" value="1" />), check_box_tag("admin", 1, true, :disabled => false, :readonly => nil)