mirror of https://github.com/apache/lucene.git
rewrite assertion to use 'assert'
git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1181299 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
f10fbf25af
commit
d526a4c699
|
@ -355,12 +355,11 @@ public class TestBooleanMinShouldMatch extends LuceneTestCase {
|
|||
found=true;
|
||||
float otherScore = top1.scoreDocs[other].score;
|
||||
// check if scores match
|
||||
if (Math.abs(otherScore-score)>1.0e-6f) {
|
||||
fail("Doc " + id + " scores don't match\n"
|
||||
+ CheckHits.topdocsString(top1,0,0)
|
||||
+ CheckHits.topdocsString(top2,0,0)
|
||||
+ "for query:" + q2.toString());
|
||||
}
|
||||
assertEquals("Doc " + id + " scores don't match\n"
|
||||
+ CheckHits.topdocsString(top1,0,0)
|
||||
+ CheckHits.topdocsString(top2,0,0)
|
||||
+ "for query:" + q2.toString(),
|
||||
score, otherScore, 1.0e-6f);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue