@@ -0,0 +1,1296 @@
+import unittest%0Aimport datetime%0Aimport hiro%0Aimport redis%0Afrom sifr.span import Minute, Day%0Afrom sifr.storage import MemoryStorage, RedisStorage%0A%0A%0Aclass RedisStorageTests(unittest.TestCase):%0A    def setUp(self):%0A        self.redis = redis.Redis()%0A        self.redis.flushall()%0A%0A    def test_incr_simple_minute(self):%0A        span = Minute(datetime.datetime.now(), %5B%22minute_span%22%5D)%0A        storage = RedisStorage(self.redis)%0A        storage.incr(span)%0A        storage.incr(span)%0A        self.assertEqual(storage.get(span), 2)%0A%0A    def test_incr_unique_minute(self):%0A        red = redis.Redis()%0A        span = Minute(datetime.datetime.now(), %5B%22minute_span%22%5D)%0A        storage = RedisStorage(red)%0A        storage.incr_unique(span, %221%22)%0A        storage.incr_unique(span, %221%22)%0A        storage.incr_unique(span, %222%22)%0A        self.assertEqual(storage.get_unique(span), 2)%0A%0A    def test_tracker_minute(self):%0A        with hiro.Timeline().freeze() as timeline:%0A            span = Minute(datetime.datetime.now(), %5B%22minute_span%22%5D)%0A            storage = RedisStorage(self.redis)%0A            storage.track(span, %221%22, 3)%0A            storage.track(span, %221%22, 3)%0A            storage.track(span, %222%22, 3)%0A            storage.track(span, %223%22, 3)%0A            self.assertEqual(storage.enumerate(span), %7B%221%22, %222%22, %223%22%7D)%0A

Add redis storage tests