Hi, I am trying to make testrules.sh run without errors on our LT rules, and have the following problem:
The following rule works fine, but the tests keep complaining about it. I suspect that the case sensitivity is playing some trick on the tests. I am running LT 2.8 currently. Any help is appreciated. Also, big thanks for creating LanguageTool! Kind Regards, Robert Fekete <rule id="syslog-ng" name="syslog-ng"> <antipattern> <token case_sensitive="yes">syslog-ng</token> </antipattern> <pattern> <token case_sensitive="yes" regexp="yes">Syslog-ng|Syslog-NG|syslogng|sysloh-ng</token> </pattern> <message>Styleguide violation: did you mean <suggestion>syslog-ng</suggestion>?</message> <short>Styleguide!</short> <example type='incorrect'> The main features of <marker>Syslog-ng</marker> are summarized below.</example> <example type='correct'> The main features of <marker>syslog-ng</marker> are summarized below.</example> </rule> The error message: Running pattern rule tests for English... Exception in thread "main" junit.framework.AssertionFailedError: Incorrect input: The main features of Syslog-ng are summarized below. Corrected sentence: The main features of Syslog-ng are summarized below. By Rule: syslog-ng[1]:[Syslog-ng|Syslog-NG|syslogng|sysloh-ng]:syslog-ng The correction triggered an error itself: syslog-ng:22-31:Styleguide violation: did you mean <suggestion>syslog-ng</suggestion>? at junit.framework.Assert.fail(Assert.java:57) at junit.framework.TestCase.fail(TestCase.java:227) at org.languagetool.rules.patterns.PatternRuleTest.testBadSentences(PatternRuleTest.java:321) at org.languagetool.rules.patterns.PatternRuleTest.testGrammarRulesFromXML(PatternRuleTest.java:238) at org.languagetool.rules.patterns.PatternRuleTest.runTestForLanguage(PatternRuleTest.java:175) at org.languagetool.rules.patterns.PatternRuleTest.runGrammarRulesFromXmlTestIgnoringLanguages(PatternRuleTest.java:144) at org.languagetool.rules.patterns.PatternRuleTest.main(PatternRuleTest.java:502)
------------------------------------------------------------------------------
_______________________________________________ Languagetool-devel mailing list Languagetool-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/languagetool-devel