use of org.languagetool.language.AustrianGerman in project languagetool by languagetool-org.
the class GermanSpellerRuleTest method testRuleWithAustrianGerman.
// note: copied from HunspellRuleTest
@Test
public void testRuleWithAustrianGerman() throws Exception {
AustrianGerman language = new AustrianGerman();
HunspellRule rule = new GermanSpellerRule(TestTools.getMessages("de"), language);
JLanguageTool lt = new JLanguageTool(language);
commonGermanAsserts(rule, lt);
// umlauts
assertEquals(0, rule.match(lt.getAnalyzedSentence("Der äußere Übeltäter.")).length);
assertEquals(1, rule.match(lt.getAnalyzedSentence("Der äussere Übeltäter.")).length);
}
use of org.languagetool.language.AustrianGerman in project languagetool by languagetool-org.
the class HunspellRuleTest method testRuleWithAustrianGerman.
@Test
public void testRuleWithAustrianGerman() throws Exception {
HunspellRule rule = new HunspellRule(TestTools.getMessages("de"), new AustrianGerman());
JLanguageTool langTool = new JLanguageTool(new German());
commonGermanAsserts(rule, langTool);
// umlauts
assertEquals(0, rule.match(langTool.getAnalyzedSentence("Der äußere Übeltäter.")).length);
assertEquals(1, rule.match(langTool.getAnalyzedSentence("Der äussere Übeltäter.")).length);
}
Aggregations