mirror of
https://github.com/jlengrand/Coding4Interviews.git
synced 2026-03-10 08:11:24 +00:00
Creates first dummy test for empty table
This commit is contained in:
@@ -21,6 +21,9 @@ class TableSorter():
|
||||
Returns the table array sorted between
|
||||
indices idx_min and idx_max using the merge sort algorithm
|
||||
"""
|
||||
if len(table) < 1:
|
||||
return None
|
||||
|
||||
if idx_max == None:
|
||||
idx_max = len(table)
|
||||
|
||||
|
||||
@@ -10,4 +10,13 @@ import unittest
|
||||
|
||||
class test_table_sorter(unittest.TestCase):
|
||||
|
||||
#TODO: Implement
|
||||
#TODO: Implement
|
||||
def test_mergeSort(self):
|
||||
|
||||
table = [1]
|
||||
sorter = TableSorter()
|
||||
self.assertEqual(None, sorter.mergeSort(table))
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
unittest.main()
|
||||
|
||||
Reference in New Issue
Block a user