sedona icon indicating copy to clipboard operation
sedona copied to clipboard

[GH-2450] chore(geopandas): write sjoin match tests for dwithin()

Open bunnysocks opened this issue 2 months ago • 0 comments

Did you read the Contributor Guide?

Is this PR related to a ticket?

  • [x] Yes, and the PR name follows the format [GH-2450] chore(geopandas): write sjoin match tests for dwithin().
    Closes #2450

What changes were proposed in this PR?

This PR adds new tests to improve coverage for Sedona’s GeoPandas integration, specifically for the sjoin() function using the predicate="dwithin" parameter.

Key updates:

  • Added a new test module test_sjoin_match.py under sedona/python/tests/geopandas/.
  • Implemented comparisons between Sedona’s and GeoPandas’ sjoin() outputs for dwithin() predicate.
  • Covered edge cases including:
    • Varying distance thresholds (0.5, 0.05, etc.)
    • Empty and small-distance joins
    • Type and integrity checks on returned GeoDataFrames

These tests aim to ensure Sedona’s spatial join behavior matches GeoPandas’ expected results and help detect future regressions.

How was this patch tested?

  • Manually verified using pytest locally.
  • Confirmed that:
    • Both Sedona and GeoPandas return equivalent results for valid dwithin() joins.
    • Output GeoDataFrames contain consistent left/right ID pairs.
  • CI will re-verify via automated testing upon PR submission.

Did this PR include necessary documentation updates?

  • [x] No, this PR does not affect any public API, so no documentation changes are required.

bunnysocks avatar Oct 31 '25 08:10 bunnysocks