You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by be...@apache.org on 2025/02/13 15:34:55 UTC
(lucene) branch main updated: Remove some randomness from flaky BaseVectorSimilarityQueryTestCase#testFallbackToExact (#14231)
This is an automated email from the ASF dual-hosted git repository.
benwtrent pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/lucene.git
The following commit(s) were added to refs/heads/main by this push:
new ba3a411bc23 Remove some randomness from flaky BaseVectorSimilarityQueryTestCase#testFallbackToExact (#14231)
ba3a411bc23 is described below
commit ba3a411bc23261cad6facfe663900d4657158ed5
Author: Benjamin Trent <be...@gmail.com>
AuthorDate: Thu Feb 13 10:34:50 2025 -0500
Remove some randomness from flaky BaseVectorSimilarityQueryTestCase#testFallbackToExact (#14231)
---
.../org/apache/lucene/search/BaseVectorSimilarityQueryTestCase.java | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/lucene/core/src/test/org/apache/lucene/search/BaseVectorSimilarityQueryTestCase.java b/lucene/core/src/test/org/apache/lucene/search/BaseVectorSimilarityQueryTestCase.java
index 06b327e9afa..2ff92d7a35e 100644
--- a/lucene/core/src/test/org/apache/lucene/search/BaseVectorSimilarityQueryTestCase.java
+++ b/lucene/core/src/test/org/apache/lucene/search/BaseVectorSimilarityQueryTestCase.java
@@ -431,8 +431,8 @@ abstract class BaseVectorSimilarityQueryTestCase<
public void testFallbackToExact() throws IOException {
// Restrictive filter, along with similarity to visit a large number of nodes
- int numFiltered = random().nextInt(numDocs / 10, numDocs / 5);
- int targetVisited = random().nextInt(numFiltered * 2, numDocs);
+ int numFiltered = numDocs / 5;
+ int targetVisited = numDocs;
V[] vectors = getRandomVectors(numDocs, dim);
V queryVector = getRandomVector(dim);