lucene-java-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mikemcc...@apache.org
Subject svn commit: r800120 - /lucene/java/trunk/contrib/fast-vector-highlighter/src/test/org/apache/lucene/search/vectorhighlight/
Date Sun, 02 Aug 2009 18:07:43 GMT
Author: mikemccand
Date: Sun Aug  2 18:07:43 2009
New Revision: 800120

URL: http://svn.apache.org/viewvc?rev=800120&view=rev
Log:
LUCENE-1522 turn on unit tests that had relied on LUCENE-1448 and LUCENE-1759

Modified:
    lucene/java/trunk/contrib/fast-vector-highlighter/src/test/org/apache/lucene/search/vectorhighlight/AbstractTestCase.java
    lucene/java/trunk/contrib/fast-vector-highlighter/src/test/org/apache/lucene/search/vectorhighlight/FieldPhraseListTest.java
    lucene/java/trunk/contrib/fast-vector-highlighter/src/test/org/apache/lucene/search/vectorhighlight/FieldTermStackTest.java
    lucene/java/trunk/contrib/fast-vector-highlighter/src/test/org/apache/lucene/search/vectorhighlight/SimpleFragListBuilderTest.java
    lucene/java/trunk/contrib/fast-vector-highlighter/src/test/org/apache/lucene/search/vectorhighlight/SimpleFragmentsBuilderTest.java

Modified: lucene/java/trunk/contrib/fast-vector-highlighter/src/test/org/apache/lucene/search/vectorhighlight/AbstractTestCase.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/contrib/fast-vector-highlighter/src/test/org/apache/lucene/search/vectorhighlight/AbstractTestCase.java?rev=800120&r1=800119&r2=800120&view=diff
==============================================================================
--- lucene/java/trunk/contrib/fast-vector-highlighter/src/test/org/apache/lucene/search/vectorhighlight/AbstractTestCase.java
(original)
+++ lucene/java/trunk/contrib/fast-vector-highlighter/src/test/org/apache/lucene/search/vectorhighlight/AbstractTestCase.java
Sun Aug  2 18:07:43 2009
@@ -206,10 +206,14 @@
       return true;
     }
 
-    public int getFinalOffset() {
+    private int getFinalOffset() {
       return nextStartOffset;
     }
     
+    public final void end(){
+      offsetAtt.setOffset(getFinalOffset(),getFinalOffset());
+    }
+    
     protected boolean getNextPartialSnippet() throws IOException {
       if( snippet != null && snippet.length() >= startTerm + 1 + n ){
         startTerm++;

Modified: lucene/java/trunk/contrib/fast-vector-highlighter/src/test/org/apache/lucene/search/vectorhighlight/FieldPhraseListTest.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/contrib/fast-vector-highlighter/src/test/org/apache/lucene/search/vectorhighlight/FieldPhraseListTest.java?rev=800120&r1=800119&r2=800120&view=diff
==============================================================================
--- lucene/java/trunk/contrib/fast-vector-highlighter/src/test/org/apache/lucene/search/vectorhighlight/FieldPhraseListTest.java
(original)
+++ lucene/java/trunk/contrib/fast-vector-highlighter/src/test/org/apache/lucene/search/vectorhighlight/FieldPhraseListTest.java
Sun Aug  2 18:07:43 2009
@@ -164,11 +164,7 @@
     assertEquals( "searchengines(1.0)((102,116))", fpl.phraseList.get( 0 ).toString() );
     assertEquals( "searchengines(1.0)((157,171))", fpl.phraseList.get( 1 ).toString() );
   }
-/*
- * ----------------------------------
- *  THIS TEST DEPENDS ON LUCENE-1448
- *  UNCOMMENT WHEN IT IS COMMITTED.
- * ----------------------------------
+
   public void test1PhraseLongMVB() throws Exception {
     makeIndexLongMVB();
 
@@ -178,5 +174,4 @@
     assertEquals( 1, fpl.phraseList.size() );
     assertEquals( "sppeeeed(1.0)((88,93))", fpl.phraseList.get( 0 ).toString() );
   }
-*/
 }

Modified: lucene/java/trunk/contrib/fast-vector-highlighter/src/test/org/apache/lucene/search/vectorhighlight/FieldTermStackTest.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/contrib/fast-vector-highlighter/src/test/org/apache/lucene/search/vectorhighlight/FieldTermStackTest.java?rev=800120&r1=800119&r2=800120&view=diff
==============================================================================
--- lucene/java/trunk/contrib/fast-vector-highlighter/src/test/org/apache/lucene/search/vectorhighlight/FieldTermStackTest.java
(original)
+++ lucene/java/trunk/contrib/fast-vector-highlighter/src/test/org/apache/lucene/search/vectorhighlight/FieldTermStackTest.java
Sun Aug  2 18:07:43 2009
@@ -146,11 +146,7 @@
     assertEquals( "search(157,163,24)", stack.pop().toString() );
     assertEquals( "engines(164,171,25)", stack.pop().toString() );
   }
-/*
- * ----------------------------------
- *  THIS TEST DEPENDS ON LUCENE-1448
- *  UNCOMMENT WHEN IT IS COMMITTED.
- * ----------------------------------
+
   public void test1PhraseMVB() throws Exception {
     makeIndexLongMVB();
     
@@ -162,5 +158,4 @@
     assertEquals( "ee(90,92,63)", stack.pop().toString() );
     assertEquals( "ed(91,93,64)", stack.pop().toString() );
   }
-*/
 }

Modified: lucene/java/trunk/contrib/fast-vector-highlighter/src/test/org/apache/lucene/search/vectorhighlight/SimpleFragListBuilderTest.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/contrib/fast-vector-highlighter/src/test/org/apache/lucene/search/vectorhighlight/SimpleFragListBuilderTest.java?rev=800120&r1=800119&r2=800120&view=diff
==============================================================================
--- lucene/java/trunk/contrib/fast-vector-highlighter/src/test/org/apache/lucene/search/vectorhighlight/SimpleFragListBuilderTest.java
(original)
+++ lucene/java/trunk/contrib/fast-vector-highlighter/src/test/org/apache/lucene/search/vectorhighlight/SimpleFragListBuilderTest.java
Sun Aug  2 18:07:43 2009
@@ -142,11 +142,7 @@
     assertEquals( 1, ffl.fragInfos.size() );
     assertEquals( "subInfos=(searchengines((102,116))searchengines((157,171)))/2.0(96,196)",
ffl.fragInfos.get( 0 ).toString() );
   }
-/*
- * ----------------------------------
- *  THIS TEST DEPENDS ON LUCENE-1448
- *  UNCOMMENT WHEN IT IS COMMITTED.
- * ----------------------------------
+
   public void test1PhraseLongMVB() throws Exception {
     makeIndexLongMVB();
 
@@ -158,5 +154,4 @@
     assertEquals( 1, ffl.fragInfos.size() );
     assertEquals( "subInfos=(sppeeeed((88,93)))/1.0(82,182)", ffl.fragInfos.get( 0 ).toString()
);
   }
-*/
 }

Modified: lucene/java/trunk/contrib/fast-vector-highlighter/src/test/org/apache/lucene/search/vectorhighlight/SimpleFragmentsBuilderTest.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/contrib/fast-vector-highlighter/src/test/org/apache/lucene/search/vectorhighlight/SimpleFragmentsBuilderTest.java?rev=800120&r1=800119&r2=800120&view=diff
==============================================================================
--- lucene/java/trunk/contrib/fast-vector-highlighter/src/test/org/apache/lucene/search/vectorhighlight/SimpleFragmentsBuilderTest.java
(original)
+++ lucene/java/trunk/contrib/fast-vector-highlighter/src/test/org/apache/lucene/search/vectorhighlight/SimpleFragmentsBuilderTest.java
Sun Aug  2 18:07:43 2009
@@ -84,11 +84,7 @@
     assertEquals( " most <b>search engines</b> use only one of these methods.
Even the <b>search engines</b> that says they can use t",
         sfb.createFragment( reader, 0, F, ffl ) );
   }
-/*
- * ----------------------------------
- *  THIS TEST DEPENDS ON LUCENE-1448
- *  UNCOMMENT WHEN IT IS COMMITTED.
- * ----------------------------------
+
   public void test1PhraseLongMVB() throws Exception {
     makeIndexLongMVB();
 
@@ -100,5 +96,4 @@
     SimpleFragmentsBuilder sfb = new SimpleFragmentsBuilder();
     assertEquals( "ssing <b>speed</b>, the", sfb.createFragment( reader, 0, F,
ffl ) );
   }
-*/
 }



Mime
View raw message