def test_add(self): image_counter = ImageCounter() image_counter.add(1) assert image_counter.get(1) == 0 image_counter.add(1, 5) assert image_counter.get(1) == 5
def test_get(self): image_counter = ImageCounter() image_counter.add(1) assert image_counter.get(1) == 0 image_counter.next(1) assert image_counter.get(1) == 1