Skip to content

Commit

Permalink
Merge pull request #1625 from neerajdotname/page_caching
Browse files Browse the repository at this point in the history
Three minor fixes to tests
  • Loading branch information
josevalim committed Jun 10, 2011
2 parents 0b02284 + 06d772c commit 2bda229
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
4 changes: 2 additions & 2 deletions actionpack/test/controller/caching_test.rb
Expand Up @@ -127,7 +127,7 @@ def test_should_obey_http_accept_attribute
assert_equal 'I am xml', @response.body
end

def test_should_cache_with_trailing_slash_on_url
def test_cached_page_should_not_have_trailing_slash_even_if_url_has_trailing_slash
@controller.class.cache_page 'cached content', '/page_caching_test/trailing_slash/'
assert File.exist?("#{FILE_STORE_PATH}/page_caching_test/trailing_slash.html")
end
Expand All @@ -141,7 +141,7 @@ def test_should_cache_ok_at_custom_path

[:ok, :no_content, :found, :not_found].each do |status|
[:get, :post, :put, :delete].each do |method|
unless method == :get and status == :ok
unless method == :get && status == :ok
define_method "test_shouldnt_cache_#{method}_with_#{status}_status" do
send(method, status)
assert_response status
Expand Down
1 change: 1 addition & 0 deletions actionpack/test/controller/content_type_test.rb
Expand Up @@ -74,6 +74,7 @@ def test_render_changed_charset_default
get :render_defaults
assert_equal "utf-16", @response.charset
assert_equal Mime::HTML, @response.content_type
ensure
OldContentTypeController.default_charset = "utf-8"
end

Expand Down

0 comments on commit 2bda229

Please sign in to comment.