MockitoException: It is not possible to mock static methods of java.lang.System to avoid interfering with class loading what leads to infinite loops