Beispiel #1
0
 def test_apply_mutation_ok(self):
     result = apply_mutation(1, cand_pop, 1, 1, prod_list_full)
     self.assertNotEqual(result, "ok")
Beispiel #2
0
 def test_apply_mutation_prod_list_blank(self):
     with self.assertRaises(ValueError):
         apply_mutation(1, cand_pop, 1, 1, None)
Beispiel #3
0
 def test_apply_mutation_hour_limit_neg(self):
     with self.assertRaises(ValueError):
         apply_mutation(1, cand_pop, 1, -1, prod_list_full)
Beispiel #4
0
 def test_apply_mutation_milk_limit_blank(self):
     with self.assertRaises(ValueError):
         apply_mutation(1, cand_pop, 0, 1, prod_list_full)
Beispiel #5
0
 def test_apply_mutation_cand_to_repro_blank(self):
     with self.assertRaises(ValueError):
         apply_mutation(1, None, 1, 1, prod_list_full)
Beispiel #6
0
 def test_apply_mutation_wished_qt_neg(self):
     with self.assertRaises(ValueError):
         apply_mutation(-1, cand_pop, 1, 1, prod_list_full)