Skip to content

Commit 2e12e83

Browse files
youthinkknorvig
authored andcommitted
Add test for distance2 in grid.py (aimacode#209)
1 parent 1085114 commit 2e12e83

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

tests/test_grid.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,10 @@ def test_distance():
1010
assert distance((1, 2), (5, 5)) == 5.0
1111

1212

13+
def test_distance2():
14+
assert distance2((1, 2), (5, 5)) == 25.0
15+
16+
1317
def test_vector_clip():
1418
assert vector_clip((-1, 10), (0, 0), (9, 9)) == (0, 9)
1519

0 commit comments

Comments
 (0)