diff --git a/actionpack/test/controller/test_test.rb b/actionpack/test/controller/test_test.rb index 29584ac201def6c1891dc35f210b9bc421737c4a..c9a30f93323961a16da6ad26f33f1036f2b26de0 100644 --- a/actionpack/test/controller/test_test.rb +++ b/actionpack/test/controller/test_test.rb @@ -291,6 +291,16 @@ def test_assert_tag_children_without_content :only => { :tag => "img" } } } } end + def test_assert_tag_attribute_matching + @response.body = '' + assert_tag :tag => 'input', + :attributes => { :name => /my/, :type => 'text' } + assert_no_tag :tag => 'input', + :attributes => { :name => 'my', :type => 'text' } + assert_no_tag :tag => 'input', + :attributes => { :name => /^my$/, :type => 'text' } + end + def test_assert_generates assert_generates 'controller/action/5', :controller => 'controller', :action => 'action', :id => '5' end