def test_should_calculate_maximum_fitness(self, cfg):
    population = ClassifiersList()
    c1 = Classifier(cfg=cfg)
    population.append(c1)
    assert (0.0 == population.get_maximum_fitness())
    c2 = Classifier(effect='1###0###', reward=0.25, cfg=cfg)
    population.append(c2)
    assert (0.125 == population.get_maximum_fitness())
    c3 = Classifier(effect='1#######', quality=0.8, reward=5, cfg=cfg)
    population.append(c3)
    assert (4 == population.get_maximum_fitness())
def test_should_calculate_maximum_fitness(self, cfg):
    population = ClassifiersList()
    c1 = Classifier(cfg=cfg)
    population.append(c1)
    assert (0.0 == population.get_maximum_fitness())
    c2 = Classifier(effect='1###0###', reward=0.25, cfg=cfg)
    population.append(c2)
    assert (0.125 == population.get_maximum_fitness())
    c3 = Classifier(effect='1#######', quality=0.8, reward=5, cfg=cfg)
    population.append(c3)
    assert (4 == population.get_maximum_fitness())