lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From robert engels <reng...@ix.netcom.com>
Subject Re: scorer.skipTo() contr
Date Wed, 06 Jun 2007 23:37:30 GMT
The method states 'greater than OR EQUAL TO' so your d1 != d2 test is  
invalid.

It should be assert (d2>=d1)

On Jun 6, 2007, at 6:30 PM, Doron Cohen wrote:

>
> Hi, following LUCENE-912, looking closer at skipTo() in
> DisjunctionMaxScorer, it seems not to follow Scorer.skipTo()  
> "contract":
>
>      "Skips to the first match beyond the current whose document  
> number is
> greater than or equal to a given target."
>
> It is the "__beyond__ the current" requirement that is not satisfied.
>
> Enhancing QueryUtils.checkSkipTo again found many failures. Roughly  
> the new
> test is:
>
>     s.skipTo(n);
>     d1 = s.doc();
>     s.skipTo(n);    // n==current
>     d2 = s.doc();
>     assert (d1 != d2)
>
> If failed for so many test cases that I have to suspect maybe I am  
> missing
> something trivial?
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: java-dev-unsubscribe@lucene.apache.org
> For additional commands, e-mail: java-dev-help@lucene.apache.org
>


---------------------------------------------------------------------
To unsubscribe, e-mail: java-dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-dev-help@lucene.apache.org


Mime
View raw message