# Path: geometry.py
# def other_side_of_point_direction(point1, point2):
#     far_behind_point = sub_2d(point2, point1)
#     direction = element_wise_round(normalize(far_behind_point))
#     return direction
# 
# def other_side_of_point(point1, point2):
#     """
#     returns the point right behind point2 as seen by point1.
#     1 = point1
#     2 = point2
#     r = result
#     ..1..
#     .....
#     .....
#     ...2.
#     ...r.
#     """
#     direction = other_side_of_point_direction(point1, point2)
#     return add_2d(point2, direction)


import unittest
from geometry import other_side_of_point_direction, other_side_of_point
        p2 = (0, 0)
        expected_r = (-1, 1)
        self.assertEqual(other_side_of_point_direction(p1, p2), expected_r)

    def test_other_side_of_point_should_return_down_when_target_is_up(self):
        """
        1, 2, r
        ...1.
        .....
        .....
        ..2..
        ..r..
        """
        p1 = (1, -3)
        p2 = (0, 0)
        expected_r = (0, 1)
        self.assertEqual(other_side_of_point(p1, p2), expected_r)

    def test_other_side_of_point_should_return_down_left_when_target_up_right(self):
        """
        1, 2, r
        .......1.
        .........
        .........
        ...2.....
        ..r......
        """
        p1 = (4, -3)
        p2 = (0, 0)
        expected_r = (-1, 1)

# Path: geometry.py
# def other_side_of_point_direction(point1, point2):
#     far_behind_point = sub_2d(point2, point1)
#     direction = element_wise_round(normalize(far_behind_point))
#     return direction
# 
# def other_side_of_point(point1, point2):
#     """
#     returns the point right behind point2 as seen by point1.
#     1 = point1
#     2 = point2
#     r = result
#     ..1..
#     .....
#     .....
#     ...2.
#     ...r.
#     """
#     direction = other_side_of_point_direction(point1, point2)
#     return add_2d(point2, direction)


# Path: geometry_test.py
import unittest
from geometry import other_side_of_point_direction, other_side_of_point

        p2 = (0, 0)
        expected_r = (-1, 1)
        self.assertEqual(other_side_of_point_direction(p1, p2), expected_r)

    def test_other_side_of_point_should_return_down_when_target_is_up(self):
        """
        1, 2, r
        ...1.
        .....
        .....
        ..2..
        ..r..
        """
        p1 = (1, -3)
        p2 = (0, 0)
        expected_r = (0, 1)
        self.assertEqual(other_side_of_point(p1, p2), expected_r)

    def test_other_side_of_point_should_return_down_left_when_target_up_right(self):
        """
        1, 2, r
        .......1.
        .........
        .........
        ...2.....
        ..r......
        """
        p1 = (4, -3)
        p2 = (0, 0)
        expected_r = (-1, 1)

        self.assertEqual(other_side_of_point(p1, p2), expected_r)