You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by iv...@apache.org on 2020/02/19 17:22:25 UTC

[lucene-solr] branch branch_8x updated: LUCENE-8707: fix test bug. when bounding box if a triangle is within a circle, the triangle is within the circle as well.

This is an automated email from the ASF dual-hosted git repository.

ivera pushed a commit to branch branch_8x
in repository https://gitbox.apache.org/repos/asf/lucene-solr.git


The following commit(s) were added to refs/heads/branch_8x by this push:
     new ac46213  LUCENE-8707: fix test bug. when bounding box if a triangle is within a circle, the triangle is within the circle as well.
ac46213 is described below

commit ac46213e83c4663fb6ffdccf505119f293887c10
Author: iverase <iv...@apache.org>
AuthorDate: Wed Feb 19 18:21:03 2020 +0100

    LUCENE-8707: fix test bug. when bounding box if a triangle
    is within a circle, the triangle is within the circle as well.
---
 lucene/core/src/test/org/apache/lucene/geo/TestCircle2D.java | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/lucene/core/src/test/org/apache/lucene/geo/TestCircle2D.java b/lucene/core/src/test/org/apache/lucene/geo/TestCircle2D.java
index 2ad5c21..3d58c8d 100644
--- a/lucene/core/src/test/org/apache/lucene/geo/TestCircle2D.java
+++ b/lucene/core/src/test/org/apache/lucene/geo/TestCircle2D.java
@@ -126,8 +126,8 @@ public class TestCircle2D extends LuceneTestCase {
         assertEquals(PointValues.Relation.CELL_OUTSIDE_QUERY, circle2D.relateTriangle(ax, ay, bx, by , cx, cy));
         assertEquals(Component2D.WithinRelation.DISJOINT, circle2D.withinTriangle(ax, ay, true, bx, by, true, cx, cy, true));
       } else if (r == PointValues.Relation.CELL_INSIDE_QUERY) {
-        assertEquals(PointValues.Relation.CELL_CROSSES_QUERY, circle2D.relateTriangle(ax, ay, bx, by , cx, cy));
-        assertEquals(Component2D.WithinRelation.NOTWITHIN, circle2D.withinTriangle(ax, ay, true, bx, by, true, cx, cy, true));
+        assertEquals(PointValues.Relation.CELL_INSIDE_QUERY, circle2D.relateTriangle(ax, ay, bx, by , cx, cy));
+        assertNotEquals(Component2D.WithinRelation.CANDIDATE, circle2D.withinTriangle(ax, ay, true, bx, by, true, cx, cy, true));
       }
     }
   }