gf2121 commented on code in PR #14419: URL: https://github.com/apache/lucene/pull/14419#discussion_r2018496277
########## lucene/core/src/test/org/apache/lucene/internal/vectorization/TestVectorUtilSupport.java: ########## @@ -210,9 +210,13 @@ public void testMinMaxScalarQuantize() { } private void assertFloatReturningProviders(ToDoubleFunction<VectorUtilSupport> func) { - assertThat( - func.applyAsDouble(PANAMA_PROVIDER.getVectorUtilSupport()), - closeTo(func.applyAsDouble(LUCENE_PROVIDER.getVectorUtilSupport()), delta)); + double luceneValue = func.applyAsDouble(LUCENE_PROVIDER.getVectorUtilSupport()); Review Comment: I was a bit surprised that we did not have a good utility to deal double equals so I grep `1e-5` in the code base. It seems we used to use `public static void assertEquals(double expected, double actual, double delta)` for this kinda assertion. It deals `NaN` well. Do we have a special reason to use `closeTo` here? -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org For additional commands, e-mail: issues-h...@lucene.apache.org