Used mockito to replicate SQLException while closing connection to show use of loggedMute

This commit is contained in:
Narendra Pathai
2016-03-15 18:44:59 +05:30
parent adb94044ff
commit 7aff77ab27
3 changed files with 48 additions and 50 deletions
@@ -50,8 +50,8 @@ public final class Mute {
/**
* Executes the <code>runnable</code> and logs the exception occurred on {@link System#err}.
* This method should be utilized to mute the operations about which most you can do is log.
* For instance while closing a connection to database, all you can do is log the exception
* occurred.
* For instance while closing a connection to database, or cleaning up a resource,
* all you can do is log the exception occurred.
*
* @param runnable a runnable that may throw an exception on execution.
*/