• xorium (unregistered)

    Looks to me like this will fail if any exception is thrown by "centralizedLogger.logAround(joinPoint);"

  • some guy (unregistered) in reply to xorium

    One would hope that an uncaught exception would fail the test no matter what BS is or isn't asserted down the line.

  • (nodebb) in reply to some guy

    Perhaps that's entirely the point. Yes, it's 137% totally obscure, especially without comments, but ...

  • (nodebb)

    It is possible that my short tenure at a major financial firm was due to me informing my manager that although our "code coverage" was over 90% there were no assert statements.

  • (nodebb)

    Cobra effect. Anything you require, no matter how stupid, will be accomplished in the easiest possible way.

  • (nodebb)

    Bonus points for annotating the instance variable centralizedLogger with @InjectMocks - it won't mock anything since there is no other mocked instance injected - and then just overwriting that same variable in the method with a new ContralizedLogger instance.

Leave a comment on “Cover Up”

Log In or post as a guest

Replying to comment #:

« Return to Article