Fix IE7+MathPlayer Bug
IE7+MathPlayer do *not* like the charset parameter to be set in the Content-Type header. Forcing Rails to omit that parameter is surprisingly difficult.
This commit is contained in:
parent
37aff87d71
commit
863d60c578
2 changed files with 34 additions and 8 deletions
|
@ -19,7 +19,24 @@ class ApplicationTest < Test::Unit::TestCase
|
|||
|
||||
def test_utf8_header
|
||||
get :show, :web => 'wiki1', :id => 'HomePage'
|
||||
assert_equal 'text/html; charset=UTF-8', @response.headers['type']
|
||||
assert_equal 'text/html; charset=utf-8', @response.headers['type']
|
||||
end
|
||||
|
||||
def test_mathplayer_mime_type
|
||||
@request.user_agent = 'MathPlayer'
|
||||
get :show, :web => 'wiki1', :id => 'HomePage'
|
||||
assert_equal 'application/xhtml+xml', @response.headers['type']
|
||||
end
|
||||
|
||||
def test_validator_mime_type
|
||||
@request.user_agent = 'Validator'
|
||||
get :show, :web => 'wiki1', :id => 'HomePage'
|
||||
assert_equal 'application/xhtml+xml; charset=utf-8', @response.headers['type']
|
||||
end
|
||||
|
||||
def test_tex_mime_type
|
||||
get :tex, :web => 'wiki1', :id => 'HomePage'
|
||||
assert_equal 'text/plain; charset=utf-8', @response.headers['type']
|
||||
end
|
||||
|
||||
def test_connect_to_model_unknown_wiki
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue