Test Runner Tab console output is unexpectedly deleted


Product: IntelliJ IDEA Ultimate 12.1.4
OS: Mac OS X 10.8.4
JDK: JDK 1.6.0_51

When I run a basic JUnit or TestNG test (let's use TestNG in this case), then the final resulting console output is indeterministic -- sometimes all of it is missing, sometime some of it, sometimes none of it. This only happens when one of two Test Runner options are selected (in the Test Runner view's gear icon drop-down menu) : "Track Running Test" and/or "Show Statistics".

1) Open the Test Runner Tab and select "Track Running Test" and "Show Statistics" (the issue is actually reproducible even when just one of these is checked).
2) Run this basic TestNG test that outputs 100 lines to stdout:

import org.testng.annotations.Test;
public class QuickTest {
  public void test1() throws Exception {

3) Look at the results in the Test Runner Tab. You should see 100 lines that say "SampleOutput". Instead, you might see none/some.

What I noticed is that when the test runs, all the desired output seems to be displayed for a very brief moment, but is then truncated as soon as the blue "Process finished with exit code 0" message appears (and then even that blue message itself disappears immediately).

What I would expect to see would be all 100 lines, and possibly the blue msg at the end.

Is anyone else able to reproduce this? If so, a fix would be most welcome. Thank you.


UPDATE: I've actually now seen this problem even without checkmarking "Track Running Test" or "Show Statistics"... the issue sometimes surfaces even with all the options unchecked. But one thing that's consistent is that I'm able to very briefly (less than a second) see the expected console output, which then immediately gets deleted as soon as the blue "Process finished with exit code 0" msg appears. Is there a way to suppress this msg meanwhile a fix is created? Thanks.
1 comment

The console output with TestNG is pretty buggy, see also http://devnet.jetbrains.com/message/5501194#5501194.  I've had to go back to eclipse until bugs like these are resolved.


Please sign in to leave a comment.