aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/test/controller
diff options
context:
space:
mode:
authorJeremy Kemper <jeremy@bitsweat.net>2008-11-08 22:43:56 -0500
committerJeremy Kemper <jeremy@bitsweat.net>2008-11-08 22:43:56 -0500
commit8bfd5edbcf842c32c5fa60d109cf7f4cd9cf60b4 (patch)
treec653b4f08535c4576d745ae960629b7fbea2c85a /actionpack/test/controller
parenteda9f49d5781a5f9a5090492a76436598faf3948 (diff)
downloadrails-8bfd5edbcf842c32c5fa60d109cf7f4cd9cf60b4.tar.gz
rails-8bfd5edbcf842c32c5fa60d109cf7f4cd9cf60b4.tar.bz2
rails-8bfd5edbcf842c32c5fa60d109cf7f4cd9cf60b4.zip
Wrap straggling mocha user with uses_mocha block
Diffstat (limited to 'actionpack/test/controller')
-rw-r--r--actionpack/test/controller/caching_test.rb12
1 files changed, 7 insertions, 5 deletions
diff --git a/actionpack/test/controller/caching_test.rb b/actionpack/test/controller/caching_test.rb
index ad160970cc..eb106c1eb4 100644
--- a/actionpack/test/controller/caching_test.rb
+++ b/actionpack/test/controller/caching_test.rb
@@ -291,11 +291,13 @@ class ActionCacheTest < ActionController::TestCase
ActionController::Base.use_accept_header = old_use_accept_header
end
- def test_action_cache_with_store_options
- MockTime.expects(:now).returns(12345).once
- @controller.expects(:read_fragment).with('hostname.com/action_caching_test', :expires_in => 1.hour).once
- @controller.expects(:write_fragment).with('hostname.com/action_caching_test', '12345.0', :expires_in => 1.hour).once
- get :index
+ uses_mocha 'test action cache' do
+ def test_action_cache_with_store_options
+ MockTime.expects(:now).returns(12345).once
+ @controller.expects(:read_fragment).with('hostname.com/action_caching_test', :expires_in => 1.hour).once
+ @controller.expects(:write_fragment).with('hostname.com/action_caching_test', '12345.0', :expires_in => 1.hour).once
+ get :index
+ end
end
def test_action_cache_with_custom_cache_path