Tibor17 commented on issue #244: [SUREFIRE-1679] Prevent classpath caching from 
causing pollution
URL: https://github.com/apache/maven-surefire/pull/244#issuecomment-521649786
   it's okay in version 2.x since these tests must be older and different from 
3.x. The reason why there is File mock is to simplify the Captures of debug 
logger because there is no physicla path and no troubles with platform and long 
lines in code. Also it is a signal for us to fail the test if the logic in 
`AbstractSurefireMojo` would change in the future when the logic would need to 
have a real paths and real reds/writes. Till that it is just in memory.
   These tests in `AbstractSurefireMojoTest.java` do not have too much 
assertion statements. They have more Captures and verifications. And the reason 
is that the class `AbstractSurefireMojo` was not developed with tests. 
Basically there was TDD on this class development. If there was I wam sure 
there could be much more assertions on returned values and less mocking of 
internal state and captures. This happens when TDD is not applied in the 
begining. Positive remark is that these tests improve the coverage and give us 
some feedback when the code is changed together with the experiences of the 

This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:

With regards,
Apache Git Services

Reply via email to