예제 #1
0
 def testISortSingleElement(self):
     self.assertEqual(hw.isort([0]), [0])
예제 #2
0
 def testISortFloatList(self):
     self.assertEqual(hw.isort([3.5, 3.0, 3.75]), [3.0, 3.5, 3.75])
예제 #3
0
 def testISortEmptyList(self):
     self.assertEqual(hw.isort([]), [])
예제 #4
0
 def testISortAlreadySorted(self):
     self.assertEqual(hw.isort([0, 1, 2, 3]), [0, 1, 2, 3])
예제 #5
0
 def testISortIntList(self):
     self.assertEqual(hw.isort([3, 1, 7, 0, 2]), [0, 1, 2, 3, 7])
 def testISortAlreadySorted(self):
     self.assertEqual(hw.isort([0,1,2,3]), [0,1,2,3])
 def testISortSingleElement(self):
     self.assertEqual(hw.isort([0]), [0]) 
 def testISortEmptyList(self):
     self.assertEqual(hw.isort([]), [])
 def testISortFloatList(self):
     self.assertEqual(hw.isort([3.5,3.0,3.75]), [3.0,3.5,3.75])
예제 #10
0
 def testISortIntList(self):
     self.assertEqual(hw.isort([3,1,7,0,2]), [0,1,2,3,7])