Exemple #1
0
 def test_best_fit(self):
     sets = bp.best_fit(self.items, self.bins, self.cap)
     self.assertEqual(sets, self.empty)
Exemple #2
0
 def test_best_fit(self):
     sets = bp.best_fit(self.items, self.bins, self.cap)
     sets[0].sort()
     self.assertEqual(sets, self.expected)
Exemple #3
0
 def test_best_fit(self):
     sets = bp.best_fit(self.items, self.bins, self.cap)
     self.expected = [[8, 2], [5], [7, 1], [6, 4], []]
     self.assertEqual(sets, self.expected)