The StreamingOutputTest seems to periodically hang on CI runs. It tends to be most common on Windows with Java SE 16/17 runs. I've not been able to reproduce this locally. However, when looking at the test there seems to be some room for improvement. The latch would use an await(int, TimeUnit) so the test will at least fail instead of hang.
The latch.coundDown() should not be done in the loop either or the CountDownLatch should be created with the correct number of expected results.