Sha256: 2dbc9de6e72e560e7c2e385791b24c3c0614add3072a2f14509b568833c423af
Contents?: true
Size: 748 Bytes
Versions: 3
Compression:
Stored size: 748 Bytes
Contents
require 'test/unit' require File.dirname(__FILE__) + '/../lib/memcache_mock' require File.dirname(__FILE__) + '/../lib/memcache_extended' class TestGeniMemcache < Test::Unit::TestCase # def memcache # MemCache.new( # :servers=>["localhost:11211"], # :ttl=>1800, # :compression=>false, # :readonly=>false, # :debug=>false, # :c_threshold=>10000, # :urlencode=>false # ) # #CACHE.servers = memcached_config[:servers] # end def test_get_reset_expiry m = MemCacheMock.new m.add('rewrite_test', 'quick brown fox', 0.1) assert_equal 'quick brown fox', m.get_reset_expiry('rewrite_test', 2) sleep(0.1) assert_equal 'quick brown fox', m.get('rewrite_test') end end
Version data entries
3 entries across 3 versions & 3 rubygems