[ 
https://issues.apache.org/jira/browse/SOLR-2163?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Robert Muir updated SOLR-2163:
------------------------------

    Attachment: SOLR-2163.patch

Here's a patch that uses Assume.assumeNoException

if the test cannot connect to the URL (), instead of seeing 5 tests pass, you 
will only see 4.
(The test is treated as if it were @Ignore, so the output looks like the below)

{noformat}
    [junit] Testsuite: org.apache.solr.servlet.SolrRequestParserTest
    [junit] Tests run: 4, Failures: 0, Errors: 0, Time elapsed: 1.585 sec
    [junit]
    [junit] ------------- Standard Output ---------------
    [junit] this test only works if you have a network connection.
    [junit] NOTE: reproduce with: ant test -Dtestcase=SolrRequestParserTest -
Dtestmethod=testStreamURL -Dtests.seed=-665
2633778166317480:-2887949451421689523
    [junit] NOTE: test params are: codec=MockFixedIntBlock(blockSize=13), 
locale=el_GR, timezone=SystemV/YST9YDT
    [junit] ------------- ---------------- ---------------
{noformat}

> SolrRequestParserTest.testStreamURL test failure
> ------------------------------------------------
>
>                 Key: SOLR-2163
>                 URL: https://issues.apache.org/jira/browse/SOLR-2163
>             Project: Solr
>          Issue Type: Bug
>          Components: Build
>    Affects Versions: 3.1, 4.0
>            Reporter: Robert Muir
>             Fix For: 3.1, 4.0
>
>         Attachments: SOLR-2163.patch
>
>
> SolrRequestParserTest.testStreamURL failed, with this error:
> this test only works if you have a network connection.
> Here is the stacktrace:
> {noformat}
>     [junit] Testsuite: org.apache.solr.servlet.SolrRequestParserTest
>     [junit] Testcase: 
> testStreamURL(org.apache.solr.servlet.SolrRequestParserTest):   FAILED
>     [junit] this test only works if you have a network connection.
>     [junit] junit.framework.AssertionFailedError: this test only works if you 
> have a network connection.
>     [junit]   at 
> org.apache.lucene.util.LuceneTestCase$LuceneTestCaseRunner.runChild(LuceneTestCase.java:795)
>     [junit]   at 
> org.apache.lucene.util.LuceneTestCase$LuceneTestCaseRunner.runChild(LuceneTestCase.java:768)
>     [junit]   at 
> org.apache.solr.servlet.SolrRequestParserTest.testStreamURL(SolrRequestParserTest.java:123)
>     [junit] 
>     [junit] 
>     [junit] Tests run: 4, Failures: 1, Errors: 0, Time elapsed: 5.7 sec
>     [junit] 
>     [junit] ------------- Standard Output ---------------
>     [junit] NOTE: reproduce with: ant test -Dtestcase=SolrRequestParserTest 
> -Dtestmethod=testStreamURL 
> -Dtests.seed=-8541875173831339371:8132050756643567111
>     [junit] NOTE: test params are: 
> codec=MockVariableIntBlock(baseBlockSize=110), locale=en_IN, 
> timezone=Pacific/Samoa
>     [junit] ------------- ---------------- ---------------
>     [junit] TEST org.apache.solr.servlet.SolrRequestParserTest FAILED
> {noformat}

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to