Uploaded image for project: 'Lucene - Core'
  1. Lucene - Core
  2. LUCENE-1348

TestTimeLimitedCollector shuold not fail if the testing machine happens to be slow

    XMLWordPrintableJSON

Details

    • Test
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • None
    • None
    • core/search
    • None
    • New

    Description

      The test fails on Hudson about once a month, like this:

      [junit] Testcase: testTimeoutNotGreedy(org.apache.lucene.search.TestTimeLimitedCollector): FAILED
      [junit] lastDoc=21 ,&& allowed=799 ,&& elapsed=900 >= 886 = ( 2*resolution + TIME_ALLOWED + SLOW_DOWN = 2*20 + 799 + 47)
      [junit] junit.framework.AssertionFailedError: lastDoc=21 ,&& allowed=799 ,&& elapsed=900 >= 886 = ( 2*resolution + TIME_ALLOWED + SLOW_DOWN = 2*20 + 799 + 47)
      [junit] at org.apache.lucene.search.TestTimeLimitedCollector.doTestTimeout(TestTimeLimitedCollector.java:189)
      [junit] at org.apache.lucene.search.TestTimeLimitedCollector.testTimeoutNotGreedy(TestTimeLimitedCollector.java:150)
      [junit]
      [junit]
      [junit] Test org.apache.lucene.search.TestTimeLimitedCollector FAILED

      Modify the test to just print a warning in this case - but still verify that there was an early termination.

      Attachments

        1. LUCENE-1348.patch
          2 kB
          Doron Cohen

        Activity

          People

            doronc Doron Cohen
            doronc Doron Cohen
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: