# Path: util.py
# def get_path(start, destination):
#     result = [start]
#     sx, sy = start
#     dx, dy = destination
#     libtcod.line_init(sx, sy, dx, dy)
#     x, y = libtcod.line_step()
#     while not x is None:
#         result.append((x, y))
#         x, y = libtcod.line_step()
#     return result


import unittest
from util import get_path


class TestComposition(unittest.TestCase):

    def setUp(self):
        pass

    def test_get_horizontal_with_same_start_and_destination_is_length_one(self):
        path = get_path((2, 4), (2, 4))
        self.assertEqual(len(path), 1)
        self.assertIn((2, 4), path)

    def test_get_horizontal_path_should_not_contain_no_duplicate_positions(self):

# Path: util.py
# def get_path(start, destination):
#     result = [start]
#     sx, sy = start
#     dx, dy = destination
#     libtcod.line_init(sx, sy, dx, dy)
#     x, y = libtcod.line_step()
#     while not x is None:
#         result.append((x, y))
#         x, y = libtcod.line_step()
#     return result


# Path: util_test.py
import unittest
from util import get_path



class TestComposition(unittest.TestCase):

    def setUp(self):
        pass

    def test_get_horizontal_with_same_start_and_destination_is_length_one(self):
        path = get_path((2, 4), (2, 4))
        self.assertEqual(len(path), 1)
        self.assertIn((2, 4), path)

    def test_get_horizontal_path_should_not_contain_no_duplicate_positions(self):

        path = get_path((0, 0), (5, 0))