Stop copying that TestSuccessException

Finally you can stop copying that TestSuccessException you write when writing tests with mocking.

I’ve put it in a jar and uploaded it to Maven Central.

<dependency>
    <groupid>be.redlab.testhelpers</groupid>
    <artifactid>testhelpers</artifactid>
    <version>1.0.0</version>
    <scope>test</scope>
</dependency>

The code is on GitHub┬áthere is also an EmptyHttpServletRequest, can be useful when calling methods that need a HttpServletRequest as parameter. ( e.g. in Mockito you can’t mock interfaces, so you can mock with the EmptyHttpServletRequest )

At the time being those where the one I needed, want to add more? Just leave an issue on GitHub and/or send a pull request for interesting stuff.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.