Make test suite compatible with Rails 4

Rails 4 changes the JSONP content_type to text/javascript
This commit is contained in:
Jo Liss 2012-09-21 16:36:42 +02:00
parent dfcbc59061
commit 646d57c438

View File

@ -214,7 +214,7 @@ class RenderJsonTest < ActionController::TestCase
def test_render_json_with_callback
get :render_json_hello_world_with_callback
assert_equal 'alert({"hello":"world"})', @response.body
assert_equal 'application/json', @response.content_type
assert_match %r(application/json|text/javascript), @response.content_type
end
def test_render_json_with_custom_content_type