Skip to content

Instantly share code, notes, and snippets.

@brynary
Created March 24, 2009 21:32
Show Gist options
  • Save brynary/84376 to your computer and use it in GitHub Desktop.
Save brynary/84376 to your computer and use it in GitHub Desktop.
class DummyCache < HashWithIndifferentAccess
attr_accessor :servers
attr_accessor :logging
def get_multi(keys)
{}
end
def set(key, value, ttl = nil, raw = false)
end
def get(key, raw = false)
end
def delete(key, options = {})
end
def incr(key, amount = 1)
end
def decr(key, amount = 1)
end
def add(key, value, ttl = nil, raw = false)
"STORED\r\n"
end
def append(key, value)
end
def namespace
nil
end
def flush_all
end
def stats
{}
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment