-
Notifications
You must be signed in to change notification settings - Fork 32
Open
Description
the test marked with "-->"
def test_count_within_range(self):
nn = KDTree_2Int()
for p in [(0, 0), (1, 0), (0, 1), (1, 1)]:
nn.add((p, id(p)))
res = nn.count_within_range((0, 0), 1)
--> self.assertEqual(3, res, "Counted %i points instead of %i" % (res, 3))
res = nn.count_within_range((0, 0), 1.9)
self.assertEqual(4, res, "Counted %i points instead of %i" % (res, 4))
fails with:
1: ======================================================================
1: FAIL: test_count_within_range (py_kdtree_test.KDTree_2IntTestCase.test_count_within_range)
1: ----------------------------------------------------------------------
1: Traceback (most recent call last):
1: File "/build/libkdtree++-0.7.5/python-bindings/py_kdtree_test.py", line 120, in test_count_within_range
1: self.assertEqual(3, res, "Counted %i points instead of %i" % (res, 3))
1: ~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1: AssertionError: 3 != 4 : Counted 4 points instead of 3
1:
The Debian "solution" used in the package was to disable the test, but I'm not sure if that is just hiding a problem.
(link to the "patch": https://salsa.debian.org/debian/libkdtreepp/-/blob/master/debian/patches/disable-improper-test.patch?ref_type=heads
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels