mirror of
https://github.com/github/rails.git
synced 2026-04-26 03:00:59 -04:00
Wrap straggling mocha user with uses_mocha block
This commit is contained in:
@@ -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
|
||||
|
||||
Reference in New Issue
Block a user