Пример #1
0
 def test_stop_search_hour_limit_neg(self):
     with self.assertRaises(ValueError):
         stop_search(-1, 1, 1, 1, cand_pop, best_fit_array_full,
                     medium_fit_array_full, 1, prod_list_full)
Пример #2
0
 def test_stop_search_hour_tolerance_blank(self):
     with self.assertRaises(ValueError):
         stop_search(1, 0, 1, 1, cand_pop, best_fit_array_full,
                     medium_fit_array_full, 1, prod_list_full)
Пример #3
0
 def test_stop_search_ok(self):
     result = stop_search(1, 1, 1, 1, cand_pop, best_fit_array_full,
                          medium_fit_array_full, 1, prod_list_full)
     self.assertNotEqual(result, "ok")
Пример #4
0
 def test_stop_search_vet_products_list_blank(self):
     with self.assertRaises(ValueError):
         stop_search(1, 1, 1, 1, cand_pop, best_fit_array_full,
                     medium_fit_array_full, 1, None)
Пример #5
0
 def test_stop_search_vet_generation_neg(self):
     with self.assertRaises(ValueError):
         stop_search(1, 1, 1, 1, cand_pop, best_fit_array_full,
                     medium_fit_array_full, -1, prod_list_full)
Пример #6
0
 def test_stop_search_medium_fit_array_blank(self):
     with self.assertRaises(ValueError):
         stop_search(1, 1, 1, 1, pop_full, best_fit_array_full, None, 1,
                     prod_list_full)
Пример #7
0
 def test_stop_search_milk_tolerance_neg(self):
     with self.assertRaises(ValueError):
         stop_search(1, 1, 1, -1, cand_pop, best_fit_array_full,
                     medium_fit_array_full, 1, prod_list_full)