From c0ad3b6b680b15578be616206c47165b17eb4f1a Mon Sep 17 00:00:00 2001 From: David Heinemeier Hansson Date: Sat, 18 Mar 2006 21:23:14 +0000 Subject: Added test for Accept header for xml_http_request calls in functional tests (closes #4222) [agkr@pobox.com] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@3948 5ecf4fe2-1ee6-0310-87b1-e25e094e27de --- actionpack/test/controller/mime_responds_test.rb | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'actionpack') diff --git a/actionpack/test/controller/mime_responds_test.rb b/actionpack/test/controller/mime_responds_test.rb index 6fe14bf65b..e696a41cb5 100644 --- a/actionpack/test/controller/mime_responds_test.rb +++ b/actionpack/test/controller/mime_responds_test.rb @@ -246,4 +246,12 @@ class MimeControllerTest < Test::Unit::TestCase get :all_types_with_layout assert_equal 'HTML for all_types_with_layout', @response.body end -end \ No newline at end of file + + def test_xhr + xhr :get, :js_or_html + assert_equal 'JS', @response.body + + xhr :get, :using_defaults + assert_equal '$("body").visualEffect("highlight");', @response.body + end +end -- cgit v1.2.3