From d4bb6912fd7123db910a1fda72c3fce5e15587fa Mon Sep 17 00:00:00 2001 From: nknize Date: Thu, 7 Apr 2016 15:23:04 -0500 Subject: [PATCH] fix bug in testLat/LonQuantization --- .../src/test/org/apache/lucene/geo/TestGeoEncodingUtils.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lucene/core/src/test/org/apache/lucene/geo/TestGeoEncodingUtils.java b/lucene/core/src/test/org/apache/lucene/geo/TestGeoEncodingUtils.java index 3b71c6388e1..f13e6c7d21b 100644 --- a/lucene/core/src/test/org/apache/lucene/geo/TestGeoEncodingUtils.java +++ b/lucene/core/src/test/org/apache/lucene/geo/TestGeoEncodingUtils.java @@ -56,7 +56,7 @@ public class TestGeoEncodingUtils extends LuceneTestCase { assertEquals(encoded, encodeLatitude(decoded)); assertEquals(encoded, encodeLatitudeCeil(decoded)); // test within the range - if (i != Integer.MAX_VALUE) { + if (encoded != Integer.MAX_VALUE) { // this is the next representable value // all double values between [min .. max) should encode to the current integer // all double values between (min .. max] should encodeCeil to the next integer. @@ -105,7 +105,7 @@ public class TestGeoEncodingUtils extends LuceneTestCase { assertEquals(encoded, encodeLongitude(decoded)); assertEquals(encoded, encodeLongitudeCeil(decoded)); // test within the range - if (i != Integer.MAX_VALUE) { + if (encoded != Integer.MAX_VALUE) { // this is the next representable value // all double values between [min .. max) should encode to the current integer // all double values between (min .. max] should encodeCeil to the next integer.