lucene-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rm...@apache.org
Subject svn commit: r1589836 - in /lucene/dev/trunk/lucene/analysis/common/src: resources/META-INF/services/org.apache.lucene.analysis.util.TokenFilterFactory test/org/apache/lucene/analysis/core/TestAllAnalyzersHaveFactories.java
Date Thu, 24 Apr 2014 19:16:03 GMT
Author: rmuir
Date: Thu Apr 24 19:16:02 2014
New Revision: 1589836

URL: http://svn.apache.org/r1589836
Log:
fix TestAllAnalysersHaveFactories to actually work, and add missing SPI entry

Modified:
    lucene/dev/trunk/lucene/analysis/common/src/resources/META-INF/services/org.apache.lucene.analysis.util.TokenFilterFactory
    lucene/dev/trunk/lucene/analysis/common/src/test/org/apache/lucene/analysis/core/TestAllAnalyzersHaveFactories.java

Modified: lucene/dev/trunk/lucene/analysis/common/src/resources/META-INF/services/org.apache.lucene.analysis.util.TokenFilterFactory
URL: http://svn.apache.org/viewvc/lucene/dev/trunk/lucene/analysis/common/src/resources/META-INF/services/org.apache.lucene.analysis.util.TokenFilterFactory?rev=1589836&r1=1589835&r2=1589836&view=diff
==============================================================================
--- lucene/dev/trunk/lucene/analysis/common/src/resources/META-INF/services/org.apache.lucene.analysis.util.TokenFilterFactory
(original)
+++ lucene/dev/trunk/lucene/analysis/common/src/resources/META-INF/services/org.apache.lucene.analysis.util.TokenFilterFactory
Thu Apr 24 19:16:02 2014
@@ -29,6 +29,7 @@ org.apache.lucene.analysis.compound.Hyph
 org.apache.lucene.analysis.core.LowerCaseFilterFactory
 org.apache.lucene.analysis.core.StopFilterFactory
 org.apache.lucene.analysis.core.TypeTokenFilterFactory
+org.apache.lucene.analysis.core.UpperCaseFilterFactory
 org.apache.lucene.analysis.cz.CzechStemFilterFactory
 org.apache.lucene.analysis.de.GermanLightStemFilterFactory
 org.apache.lucene.analysis.de.GermanMinimalStemFilterFactory

Modified: lucene/dev/trunk/lucene/analysis/common/src/test/org/apache/lucene/analysis/core/TestAllAnalyzersHaveFactories.java
URL: http://svn.apache.org/viewvc/lucene/dev/trunk/lucene/analysis/common/src/test/org/apache/lucene/analysis/core/TestAllAnalyzersHaveFactories.java?rev=1589836&r1=1589835&r2=1589836&view=diff
==============================================================================
--- lucene/dev/trunk/lucene/analysis/common/src/test/org/apache/lucene/analysis/core/TestAllAnalyzersHaveFactories.java
(original)
+++ lucene/dev/trunk/lucene/analysis/common/src/test/org/apache/lucene/analysis/core/TestAllAnalyzersHaveFactories.java
Thu Apr 24 19:16:02 2014
@@ -112,6 +112,7 @@ public class TestAllAnalyzersHaveFactori
         || testComponents.contains(c)
         || crazyComponents.contains(c)
         || oddlyNamedComponents.contains(c)
+        || c.isAnnotationPresent(Deprecated.class) // deprecated ones are typically back
compat hacks
         || !(Tokenizer.class.isAssignableFrom(c) || TokenFilter.class.isAssignableFrom(c)
|| CharFilter.class.isAssignableFrom(c))
       ) {
         continue;
@@ -133,7 +134,7 @@ public class TestAllAnalyzersHaveFactori
           }
           assertSame(c, instance.create().getClass());
         } catch (IllegalArgumentException e) {
-          if (!e.getMessage().contains("SPI")) {
+          if (!e.getMessage().contains("SPI") || e.getMessage().contains("does not exist"))
{
             throw e;
           }
           // TODO: For now pass because some factories have not yet a default config that
always works
@@ -155,7 +156,7 @@ public class TestAllAnalyzersHaveFactori
             assertSame(c, createdClazz);
           }
         } catch (IllegalArgumentException e) {
-          if (!e.getMessage().contains("SPI")) {
+          if (!e.getMessage().contains("SPI") || e.getMessage().contains("does not exist"))
{
             throw e;
           }
           // TODO: For now pass because some factories have not yet a default config that
always works
@@ -177,7 +178,7 @@ public class TestAllAnalyzersHaveFactori
             assertSame(c, createdClazz);
           }
         } catch (IllegalArgumentException e) {
-          if (!e.getMessage().contains("SPI")) {
+          if (!e.getMessage().contains("SPI") || e.getMessage().contains("does not exist"))
{
             throw e;
           }
           // TODO: For now pass because some factories have not yet a default config that
always works



Mime
View raw message