mirror of https://github.com/apache/lucene.git
LUCENE-2880: Relax assertion: span near and phrase queries don't have the same scores if they wrap twice the same term.
git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1686337 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
9f8635de07
commit
982a965832
|
@ -154,7 +154,11 @@ public class TestSpanSearchEquivalence extends SearchEquivalenceTestBase {
|
|||
};
|
||||
SpanQuery q1 = spanQuery(new SpanNearQuery(subquery, 0, true));
|
||||
PhraseQuery q2 = new PhraseQuery(t1.field(), t1.bytes(), t2.bytes());
|
||||
assertSameScores(q1, q2);
|
||||
if (t1.equals(t2)) {
|
||||
assertSameSet(q1, q2);
|
||||
} else {
|
||||
assertSameScores(q1, q2);
|
||||
}
|
||||
}
|
||||
|
||||
/** SpanNearQuery([A, B], ∞, false) = +A +B */
|
||||
|
|
Loading…
Reference in New Issue