From c3294bb4ddca6aa505e324eb43af3556709a16ad Mon Sep 17 00:00:00 2001 From: Yu Ting Date: Sun, 10 Apr 2016 17:06:23 +0800 Subject: [PATCH] Add test for distance2 in grid.py --- tests/test_grid.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tests/test_grid.py b/tests/test_grid.py index b7da02121..2bfea35e0 100644 --- a/tests/test_grid.py +++ b/tests/test_grid.py @@ -10,6 +10,10 @@ def test_distance(): assert distance((1, 2), (5, 5)) == 5.0 +def test_distance2(): + assert distance2((1, 2), (5, 5)) == 25.0 + + def test_vector_clip(): assert vector_clip((-1, 10), (0, 0), (9, 9)) == (0, 9)