Ejemplo n.º 1
0
 def test_worst_fit(self):
     sets = bp.worst_fit(self.items, self.bins, self.cap)
     self.assertEqual(sets, self.empty)
Ejemplo n.º 2
0
 def test_worst_fit(self):
     sets = bp.worst_fit(self.items, self.bins, self.cap)
     sets[0].sort()
     self.assertEqual(sets, self.expected)
Ejemplo n.º 3
0
 def test_worst_fit(self):
     self.bins = 4
     sets = bp.worst_fit(self.items, self.bins, self.cap)
     self.expected = [[8], [5, 2, 1], [7], [6, 4]]
     self.assertEqual(sets, self.expected)