diff options
author | Stephen Celis <stephen@stephencelis.com> | 2010-01-05 08:32:00 -0600 |
---|---|---|
committer | José Valim <jose.valim@gmail.com> | 2010-01-14 01:07:04 +0100 |
commit | 2835ec6134b1e5b706824b568dfaba24672b7409 (patch) | |
tree | 59e6374eea994e65c08132cff7824ba75ff25b4d /actionpack/test | |
parent | 214b548485f9313639059e8de1ad08611f734fe2 (diff) | |
download | rails-2835ec6134b1e5b706824b568dfaba24672b7409.tar.gz rails-2835ec6134b1e5b706824b568dfaba24672b7409.tar.bz2 rails-2835ec6134b1e5b706824b568dfaba24672b7409.zip |
Custom 'type' attribute support for text_field. [#3646 status:resolved]
Signed-off-by: José Valim <jose.valim@gmail.com>
Diffstat (limited to 'actionpack/test')
-rw-r--r-- | actionpack/test/template/form_helper_test.rb | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/actionpack/test/template/form_helper_test.rb b/actionpack/test/template/form_helper_test.rb index 7712883e9c..454b6159ab 100644 --- a/actionpack/test/template/form_helper_test.rb +++ b/actionpack/test/template/form_helper_test.rb @@ -201,6 +201,11 @@ class FormHelperTest < ActionView::TestCase hidden_field("post", "title", :value => "Something Else") end + def test_text_field_with_custom_type + assert_dom_equal '<input id="user_email" size="30" name="user[email]" type="email" />', + text_field("user", "email", :type => "email") + end + def test_check_box assert_dom_equal( '<input name="post[secret]" type="hidden" value="0" /><input checked="checked" id="post_secret" name="post[secret]" type="checkbox" value="1" />', |