def test_next_rotation_id_is_0_without_match(self): rotated_files = list(rotator._rotated_files("tests/test_dir_a/foo")) x = rotator._next_rotation_id(rotated_files) self.assertEqual(x, 0)
def test_finds_next_rotation_id(self): rotated_files = list(rotator._rotated_files("tests/test_dir_a/mydump")) x = rotator._next_rotation_id(rotated_files) self.assertEqual(x, 8)