Revision: 9365
http://languagetool.svn.sourceforge.net/languagetool/?rev=9365&view=rev
Author: dnaber
Date: 2013-02-12 22:25:28 +0000 (Tue, 12 Feb 2013)
Log Message:
-----------
re-activate the false-friend rule check (was lost on switch to Maven)
Modified Paths:
--------------
trunk/languagetool/languagetool-standalone/src/main/resources/testrules.bat
trunk/languagetool/languagetool-standalone/src/main/resources/testrules.sh
Added Paths:
-----------
trunk/languagetool/languagetool-core/src/test/java/org/languagetool/ValidateFalseFriendsXmlTest.java
Copied:
trunk/languagetool/languagetool-core/src/test/java/org/languagetool/ValidateFalseFriendsXmlTest.java
(from rev 9047,
trunk/JLanguageTool/src/test/java/org/languagetool/ValidateXMLTest.java)
===================================================================
---
trunk/languagetool/languagetool-core/src/test/java/org/languagetool/ValidateFalseFriendsXmlTest.java
(rev 0)
+++
trunk/languagetool/languagetool-core/src/test/java/org/languagetool/ValidateFalseFriendsXmlTest.java
2013-02-12 22:25:28 UTC (rev 9365)
@@ -0,0 +1,42 @@
+/* LanguageTool, a natural language style checker
+ * Copyright (C) 2006 Daniel Naber (http://www.danielnaber.de)
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301
+ * USA
+ */
+package org.languagetool;
+
+import java.io.IOException;
+
+import junit.framework.TestCase;
+
+public class ValidateFalseFriendsXmlTest extends TestCase {
+
+ public void testFalseFriendsXML() throws IOException {
+ System.out.println("Validating false-friends.xml...");
+ final XMLValidator validator = new XMLValidator();
+ validator.validate(JLanguageTool.getDataBroker().getRulesDir() +
"/false-friends.xml",
+ JLanguageTool.getDataBroker().getRulesDir() +
"/false-friends.dtd", "rules");
+ System.out.println("Validation successfully finished.");
+ }
+
+ /**
+ * Validator, for non-programmers developing rules.
+ */
+ public static void main(final String[] args) throws IOException {
+ final ValidateFalseFriendsXmlTest test = new ValidateFalseFriendsXmlTest();
+ test.testFalseFriendsXML();
+ }
+}
Modified:
trunk/languagetool/languagetool-standalone/src/main/resources/testrules.bat
===================================================================
--- trunk/languagetool/languagetool-standalone/src/main/resources/testrules.bat
2013-02-12 22:11:48 UTC (rev 9364)
+++ trunk/languagetool/languagetool-standalone/src/main/resources/testrules.bat
2013-02-12 22:25:28 UTC (rev 9365)
@@ -5,3 +5,4 @@
java -cp %CPATH% org.languagetool.rules.patterns.PatternRuleTest %1
java -cp %CPATH%
org.languagetool.tagging.disambiguation.rules.DisambiguationRuleTest %1
java -cp %CPATH% org.languagetool.rules.bitext.BitextPatternRuleTest %1
+java -cp %CPATH% org.languagetool.ValidateFalseFriendsXmlTest
Modified:
trunk/languagetool/languagetool-standalone/src/main/resources/testrules.sh
===================================================================
(Binary files differ)
This was sent by the SourceForge.net collaborative development platform, the
world's largest Open Source development site.
------------------------------------------------------------------------------
Free Next-Gen Firewall Hardware Offer
Buy your Sophos next-gen firewall before the end March 2013
and get the hardware for free! Learn more.
http://p.sf.net/sfu/sophos-d2d-feb
_______________________________________________
Languagetool-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/languagetool-commits