You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by yo...@apache.org on 2010/10/15 02:50:53 UTC

svn commit: r1022793 - /lucene/dev/trunk/solr/src/test/org/apache/solr/handler/component/SpellCheckComponentTest.java

Author: yonik
Date: Fri Oct 15 00:50:53 2010
New Revision: 1022793

URL: http://svn.apache.org/viewvc?rev=1022793&view=rev
Log:
tests: fix resource leaks

Modified:
    lucene/dev/trunk/solr/src/test/org/apache/solr/handler/component/SpellCheckComponentTest.java

Modified: lucene/dev/trunk/solr/src/test/org/apache/solr/handler/component/SpellCheckComponentTest.java
URL: http://svn.apache.org/viewvc/lucene/dev/trunk/solr/src/test/org/apache/solr/handler/component/SpellCheckComponentTest.java?rev=1022793&r1=1022792&r2=1022793&view=diff
==============================================================================
--- lucene/dev/trunk/solr/src/test/org/apache/solr/handler/component/SpellCheckComponentTest.java (original)
+++ lucene/dev/trunk/solr/src/test/org/apache/solr/handler/component/SpellCheckComponentTest.java Fri Oct 15 00:50:53 2010
@@ -145,7 +145,7 @@ public class SpellCheckComponentTest ext
     spellchecker.add(AbstractLuceneSpellChecker.INDEX_DIR, "spellchecker1");
     args.add("spellchecker", spellchecker);
 
-    // TODO: this is really fragile - find a higher level way to test this.
+    // TODO: this is really fragile and error prone - find a higher level way to test this.
     SpellCheckComponent checker = new SpellCheckComponent();
     checker.init(args);
     checker.inform(h.getCore());
@@ -164,6 +164,8 @@ public class SpellCheckComponentTest ext
     } catch (NullPointerException e) {
       fail("NullPointerException due to reload not initializing analyzers");
     }
+
+    rb.req.close();
   }
   
     @SuppressWarnings("unchecked")