aboutsummaryrefslogtreecommitdiffstats
path: root/activesupport/test
diff options
context:
space:
mode:
authorBrian Durand <brian@embellishedvisions.com>2011-08-01 12:05:29 -0500
committerBrian Durand <brian@embellishedvisions.com>2011-08-01 12:05:29 -0500
commitfec4c5ad76a4955364e091296b68bb7ac12bc928 (patch)
tree2331a32ebbae17a7f916e6c927f96de9e5206ef5 /activesupport/test
parentcaacf85673b880d22d23443e32c24234e3b2f347 (diff)
downloadrails-fec4c5ad76a4955364e091296b68bb7ac12bc928.tar.gz
rails-fec4c5ad76a4955364e091296b68bb7ac12bc928.tar.bz2
rails-fec4c5ad76a4955364e091296b68bb7ac12bc928.zip
Pass options in ActiveSupport::Cache::CacheStore#read_multi through to the delete_entry call.
Diffstat (limited to 'activesupport/test')
-rw-r--r--activesupport/test/caching_test.rb8
1 files changed, 8 insertions, 0 deletions
diff --git a/activesupport/test/caching_test.rb b/activesupport/test/caching_test.rb
index 402c6695aa..5e6a2102e0 100644
--- a/activesupport/test/caching_test.rb
+++ b/activesupport/test/caching_test.rb
@@ -199,6 +199,14 @@ module CacheStoreBehavior
@cache.write('fud', 'biz')
assert_equal({"foo" => "bar", "fu" => "baz"}, @cache.read_multi('foo', 'fu'))
end
+
+ def test_read_multi_with_expires
+ @cache.write('foo', 'bar', :expires_in => 0.001)
+ @cache.write('fu', 'baz')
+ @cache.write('fud', 'biz')
+ sleep(0.002)
+ assert_equal({"fu" => "baz"}, @cache.read_multi('foo', 'fu'))
+ end
def test_read_and_write_compressed_small_data
@cache.write('foo', 'bar', :compress => true)