I have an application where I want to write unit tests to test the output, written to System.out (and perhaps System.err). Each individual test works as expected, however when adding multiple tests in the same class some tests fail because JUnit4 appears to be multi-threaded (thus no guarantees exists on when exactly the stream is reset). The same happens when I separate all test methods in their own class and use a test suite.I have an application where I want to write uni