From e1786ee6ebee9fab10d6756be1eeacbbe6b65b48 Mon Sep 17 00:00:00 2001 From: Yehuda Katz Date: Mon, 26 Oct 2009 17:32:42 -0700 Subject: Fixes expires_now and cleans things up a bit --- actionpack/test/controller/render_test.rb | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'actionpack/test/controller') diff --git a/actionpack/test/controller/render_test.rb b/actionpack/test/controller/render_test.rb index 2db524ca4b..ac8dad7c42 100644 --- a/actionpack/test/controller/render_test.rb +++ b/actionpack/test/controller/render_test.rb @@ -73,6 +73,11 @@ class TestController < ActionController::Base render :action => 'hello_world' end + def conditional_hello_with_expires_now + expires_now + render :action => 'hello_world' + end + def conditional_hello_with_bangs render :action => 'hello_world' end @@ -1321,6 +1326,11 @@ class ExpiresInRenderTest < ActionController::TestCase get :conditional_hello_with_expires_in_with_public_with_more_keys_old_syntax assert_equal "max-age=60, public, max-stale=18000", @response.headers["Cache-Control"] end + + def test_expires_now + get :conditional_hello_with_expires_now + assert_equal "no-cache", @response.headers["Cache-Control"] + end end -- cgit v1.2.3