def test_redis_legacy(): # ensure the old interface isn't broken, but doesn't trace tracer = get_dummy_tracer() TracedRedisCache = get_traced_redis(tracer, 'foo') r = TracedRedisCache(port=REDIS_CONFIG['port']) r.set('a', 'b') got = r.get('a') assert compat.to_unicode(got) == 'b' assert not tracer.writer.pop()
def test_redis_legacy(): # ensure the old interface isn't broken, but doesn't trace tracer = get_dummy_tracer() TracedRedisCache = get_traced_redis(tracer, "foo") r = TracedRedisCache(port=REDIS_CONFIG['port']) r.set("a", "b") got = r.get("a") eq_(compat.to_unicode(got), "b") assert not tracer.writer.pop()