Skip to content

Commit

Permalink
log the warning message when it will fail
Browse files Browse the repository at this point in the history
  • Loading branch information
gaol committed Dec 17, 2019
1 parent b272354 commit 04fabf0
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -23,3 +23,4 @@ src/gen
.vertx
sonar-project.properties
.sonar*
generated
4 changes: 2 additions & 2 deletions src/test/java/io/vertx/ext/mail/SMTPTestBase.java
Original file line number Diff line number Diff line change
Expand Up @@ -197,11 +197,11 @@ protected void testException(MailClient mailClient, MailMessage email, Class<? e
testContext.fail("this test should throw an Exception");
} else {
final Throwable cause = result.cause();
log.warn("got exception", cause);
if(exceptionClass == null || exceptionClass.equals(cause.getClass())) {
async.complete();
} else {
testContext.fail("didn't get expected exception "+exceptionClass+" but "+cause.getClass());
log.warn("got exception", cause);
testContext.fail("didn't get expected exception " + exceptionClass + " but " + cause.getClass());
}
}
});
Expand Down

0 comments on commit 04fabf0

Please sign in to comment.