Commit 2117b756 authored by Joseph Siddons's avatar Joseph Siddons
Browse files

test: fix quadtree length test - exclude point outside boundary from expected length

parent 4cd77c10
......@@ -81,7 +81,7 @@ class TestQuadTree(unittest.TestCase):
Record(10, 5),
Record(19, 1),
Record(0, 0),
Record(-2, -9.2),
Record(-2, -9.2), # Not included
Record(12.8, 2.1),
]
expected = [
......@@ -94,7 +94,7 @@ class TestQuadTree(unittest.TestCase):
for point in points:
qtree.insert(point)
assert qtree.divided
assert qtree.len() == len(points)
assert qtree.len() == len(points) - 1
res = [
qtree.points,
qtree.northwest.points,
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment