aboutsummaryrefslogtreecommitdiffstats
path: root/activesupport/test
diff options
context:
space:
mode:
authorArthur Neves <arthurnn@gmail.com>2014-01-03 15:39:33 -0500
committerArthur Neves <arthurnn@gmail.com>2014-01-03 15:39:33 -0500
commit98458eea425d15ebadf366d8b55fc89c1913d146 (patch)
treed84e6121405db3ed34476febf75cc63b86dc8b7e /activesupport/test
parentf89266ace88b489a6af48fa4ae749a0e159112b6 (diff)
downloadrails-98458eea425d15ebadf366d8b55fc89c1913d146.tar.gz
rails-98458eea425d15ebadf366d8b55fc89c1913d146.tar.bz2
rails-98458eea425d15ebadf366d8b55fc89c1913d146.zip
mem_cache_store requires dalli, so only accept dalli/client
:mem_cache_store require dalli, rescue Dalli exceptions, and follow Dalli API. Memcached gem, for instance, doesnt work anymore, as the API are different. As we already require one client, we should make sure that client works, and not accept others, and if someone wants to use another memcache client they can write their own store adapter.
Diffstat (limited to 'activesupport/test')
-rw-r--r--activesupport/test/caching_test.rb8
1 files changed, 0 insertions, 8 deletions
diff --git a/activesupport/test/caching_test.rb b/activesupport/test/caching_test.rb
index 51007402a1..09781f3e7a 100644
--- a/activesupport/test/caching_test.rb
+++ b/activesupport/test/caching_test.rb
@@ -110,14 +110,6 @@ class CacheStoreSettingTest < ActiveSupport::TestCase
assert_kind_of(ActiveSupport::Cache::MemCacheStore, store)
end
- def test_mem_cache_fragment_cache_store_with_given_mem_cache_like_object
- Dalli::Client.expects(:new).never
- memcache = Object.new
- def memcache.get() true end
- store = ActiveSupport::Cache.lookup_store :mem_cache_store, memcache
- assert_kind_of(ActiveSupport::Cache::MemCacheStore, store)
- end
-
def test_mem_cache_fragment_cache_store_with_multiple_servers
Dalli::Client.expects(:new).with(%w[localhost 192.168.1.1], {})
store = ActiveSupport::Cache.lookup_store :mem_cache_store, "localhost", '192.168.1.1'