aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/test/template/erb
diff options
context:
space:
mode:
Diffstat (limited to 'actionpack/test/template/erb')
-rw-r--r--actionpack/test/template/erb/form_for_test.rb2
-rw-r--r--actionpack/test/template/erb/tag_helper_test.rb4
2 files changed, 3 insertions, 3 deletions
diff --git a/actionpack/test/template/erb/form_for_test.rb b/actionpack/test/template/erb/form_for_test.rb
index ec6e872735..e722b40a9a 100644
--- a/actionpack/test/template/erb/form_for_test.rb
+++ b/actionpack/test/template/erb/form_for_test.rb
@@ -5,7 +5,7 @@ module ERBTest
class TagHelperTest < BlockTestCase
test "form_for works" do
output = render_content "form_for(:staticpage, :url => {:controller => 'blah', :action => 'update'})", ""
- assert_equal "<form action=\"/blah/update\" method=\"post\"></form>", output
+ assert_match %r{<form.*action="/blah/update".*method="post">.*</form>}, output
end
end
end
diff --git a/actionpack/test/template/erb/tag_helper_test.rb b/actionpack/test/template/erb/tag_helper_test.rb
index 64a88bde1d..d073100986 100644
--- a/actionpack/test/template/erb/tag_helper_test.rb
+++ b/actionpack/test/template/erb/tag_helper_test.rb
@@ -28,8 +28,8 @@ module ERBTest
end
test "percent equals works with form tags" do
- expected_output = "<form action=\"foo\" method=\"post\">hello</form>"
- maybe_deprecated { assert_equal expected_output, render_content("form_tag('foo')", "<%= 'hello' %>") }
+ expected_output = %r{<form.*action="foo".*method="post">.*hello*</form>}
+ maybe_deprecated { assert_match expected_output, render_content("form_tag('foo')", "<%= 'hello' %>") }
end
test "percent equals works with fieldset tags" do