def test_delete_group_counter(self, redis): counter = RunningCounter(redis, 1, 1, group_name='group') counter.inc(name="name1") counter.delete(name="name1") assert counter.group_counts() == {} counter.inc(name="name1") counter.inc(name="name2") counter.delete_group() assert counter.group_counts() == {}
def test_delete_counter(self, redis): counter = RunningCounter(redis, 1, 1, name='name1') counter.inc() counter.delete() assert counter.count() == 0