Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
In working on #58, I noticed two of the test cases each have an extra point in their expected result to compensate for rounding errors. Instead of just a point at
[-1783,-3]
, they each have two points:[-1783,-3]
and[-1783,-2.999999999999999]
.This PR fixes that issue.
In looking into that, I found out that the intersect function is being overzealous in applying the
noEndpointTouch
option - ie. returning null in cases when the intersection is not an endpoint of either line. That situation isn't being exercised by the test suite. This PR adds test cases for that and fixes that issue as well.Again, thanks for you all for your work on martinez, very very helpful. Let me know if there's any tweaks you'd like to see to this PR. Cheers.