Uwe's answer really nails it (please do use ant test-help -- it's for
you after all!) but wanted to add a note about this question:

> I think the output is logged to a file somewhere, but I do not know where.

The raw output of a JVM process running tests is logged for internal
purposes only, you should't look at it or need it -- it doesn't
contain any information about which test dumped what output, for
example (this demarcation is kept separately). If you wish to see all
test and all of the sysouts they've made then "ant test-help" gives
you all the information about the report files:

     [help] # Output test files and reports.
     [help] ${tests-output}/tests-report.txt    - full ASCII tests report
     [help] ${tests-output}/tests-failures.txt  - failures only (if any)
     [help] ${tests-output}/tests-report-*      - HTML5 report with results
     [help] ${tests-output}/junit4-*.suites     - per-JVM executed suites
     [help]                                       (important if job stealing).

Dawid

On Wed, Feb 25, 2015 at 1:50 AM, Shawn Heisey <[email protected]> wrote:
> On 2/24/2015 4:15 PM, S G wrote:
>> Hi,
>>
>> I want to print some information in a Solr test.
>> But I am unable to get it to print on console or file.
>>
>> I have tried System.out.println and log.error but the output is not
>> coming anywhere.
>> log4j.properties also looks ok to me.
>>
>> Command run:
>>     ant test -Dtestcase=CloudSolrClientTest
>>
>> Can someone help me point in the right direction?
>
> If the test passes, the output will not normally be seen.  I think the
> output is logged to a file somewhere, but I do not know where.  If you
> want to see the output in your console, just force the test to fail.
> That should show you everything.
>
> In the org.junit.Assert class, there is a fail() method that you should
> be able to temporarily insert at the end of your test so that all test
> output will be shown.
>
> Thanks,
> Shawn
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
>

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

Reply via email to