

def test_add_iteration(self):
    sla = outliers.Outliers({
        'max': 1,
    })
    first_iterations = [3.1, 4.2, 3.6, 4.5, 2.8, 3.3, 4.1, 3.8, 4.3, 2.9, 10.2]
    for d in first_iterations:
        self.assertTrue(sla.add_iteration({
            'duration': d,
        }))
    self.assertFalse(sla.add_iteration({
        'duration': 11.2,
    }))
    self.assertFalse(sla.add_iteration({
        'duration': 3.4,
    }))

dataset/ETHPy150Open openstack/rally/tests/unit/plugins/common/sla/test_ouliers.py OutliersTestCase.test_add_iteration/original