Exemplo n.º 1
0
    def test_sort_should_order_the_items_of_the_given_list_in_ascendent_fashion(self):
        result = sort.sort_list(self.unsorted_list)

        self.assertEqual([1,3,5,6,8,9],result)
Exemplo n.º 2
0
    def test_sort_should_do_nothing_if_the_list_is_already_sorted(self):
        result = sort.sort_list(self.sorted_short_list)

        self.assertEqual([1, 2, 3], result)
Exemplo n.º 3
0
    def test_sort_should_do_nothing_if_an_empty_list_is_passed(self):
        result = sort.sort_list(self.empty_list)

        self.assertEqual([], result)
Exemplo n.º 4
0
    def test_sort_should_order_the_items_of_the_given_list_in_ascendent_fashion(
            self):
        result = sort.sort_list(self.unsorted_list)

        self.assertEqual([1, 3, 5, 6, 8, 9], result)
Exemplo n.º 5
0
    def test_sort_should_do_nothing_if_the_list_is_already_sorted(self):
        result = sort.sort_list(self.sorted_short_list)

        self.assertEqual([1, 2, 3], result)
Exemplo n.º 6
0
    def test_sort_should_do_nothing_if_an_empty_list_is_passed(self):
        result = sort.sort_list(self.empty_list)

        self.assertEqual([], result)