LUCENE-3929: add a test demonstrating this works

git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1305870 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Robert Muir 2012-03-27 15:16:42 +00:00
parent a2b98d9a51
commit bca62a44d3
1 changed files with 8 additions and 0 deletions

View File

@ -19,6 +19,7 @@ package org.apache.lucene.analysis.fr;
import java.io.IOException;
import org.apache.lucene.analysis.Analyzer;
import org.apache.lucene.analysis.BaseTokenStreamTestCase;
import org.apache.lucene.analysis.util.CharArraySet;
import org.apache.lucene.util.Version;
@ -264,4 +265,11 @@ public class TestFrenchAnalyzer extends BaseTokenStreamTestCase {
public void testRandomStrings() throws Exception {
checkRandomData(random, new FrenchAnalyzer(TEST_VERSION_CURRENT), 10000*RANDOM_MULTIPLIER);
}
/** test accent-insensitive */
public void testAccentInsensitive() throws Exception {
Analyzer a = new FrenchAnalyzer(TEST_VERSION_CURRENT);
checkOneTermReuse(a, "sécuritaires", "securitair");
checkOneTermReuse(a, "securitaires", "securitair");
}
}