mirror of https://github.com/apache/lucene.git
LUCENE-6423: blacklist broken variants of LimitTokenOffsetFilter from testing
git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1675513 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
e86dec2058
commit
88831572bf
|
@ -70,6 +70,7 @@ import org.apache.lucene.analysis.hunspell.Dictionary;
|
||||||
import org.apache.lucene.analysis.hunspell.TestHunspellStemFilter;
|
import org.apache.lucene.analysis.hunspell.TestHunspellStemFilter;
|
||||||
import org.apache.lucene.analysis.miscellaneous.HyphenatedWordsFilter;
|
import org.apache.lucene.analysis.miscellaneous.HyphenatedWordsFilter;
|
||||||
import org.apache.lucene.analysis.miscellaneous.LimitTokenCountFilter;
|
import org.apache.lucene.analysis.miscellaneous.LimitTokenCountFilter;
|
||||||
|
import org.apache.lucene.analysis.miscellaneous.LimitTokenOffsetFilter;
|
||||||
import org.apache.lucene.analysis.miscellaneous.LimitTokenPositionFilter;
|
import org.apache.lucene.analysis.miscellaneous.LimitTokenPositionFilter;
|
||||||
import org.apache.lucene.analysis.miscellaneous.StemmerOverrideFilter;
|
import org.apache.lucene.analysis.miscellaneous.StemmerOverrideFilter;
|
||||||
import org.apache.lucene.analysis.miscellaneous.StemmerOverrideFilter.StemmerOverrideMap;
|
import org.apache.lucene.analysis.miscellaneous.StemmerOverrideFilter.StemmerOverrideMap;
|
||||||
|
@ -128,6 +129,18 @@ public class TestRandomChains extends BaseTokenStreamTestCase {
|
||||||
return !((Boolean) args[2]); // args are broken if consumeAllTokens is false
|
return !((Boolean) args[2]); // args are broken if consumeAllTokens is false
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
brokenConstructors.put(
|
||||||
|
LimitTokenOffsetFilter.class.getConstructor(TokenStream.class, int.class),
|
||||||
|
ALWAYS);
|
||||||
|
brokenConstructors.put(
|
||||||
|
LimitTokenOffsetFilter.class.getConstructor(TokenStream.class, int.class, boolean.class),
|
||||||
|
new Predicate<Object[]>() {
|
||||||
|
@Override
|
||||||
|
public boolean apply(Object[] args) {
|
||||||
|
assert args.length == 3;
|
||||||
|
return !((Boolean) args[2]); // args are broken if consumeAllTokens is false
|
||||||
|
}
|
||||||
|
});
|
||||||
brokenConstructors.put(
|
brokenConstructors.put(
|
||||||
LimitTokenPositionFilter.class.getConstructor(TokenStream.class, int.class),
|
LimitTokenPositionFilter.class.getConstructor(TokenStream.class, int.class),
|
||||||
ALWAYS);
|
ALWAYS);
|
||||||
|
|
Loading…
Reference in New Issue