From: David Pursehouse Date: Tue, 17 Jul 2018 01:43:04 +0000 (+0900) Subject: ErrorProne: Enable check for misuse of ExpectedException X-Git-Tag: v5.1.0.201808281540-m3~48^2 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=refs%2Fchanges%2F44%2F126144%2F2;p=jgit.git ErrorProne: Enable check for misuse of ExpectedException Any additional statements after the statement that is expected to throw will never be executed in a passing test. This can lead to inappropriately passing tests where later incorrect assertions are skipped by the thrown exception. See [1] for examples. There are no cases of this in the code base, but by enabling the checker with severity ERROR we can ensure that we don't overlook any future misuse of ExpectedException. [1] http://errorprone.info/bugpattern/ExpectedExceptionChecker Change-Id: I266d4f73f6075bfc1e39fa3d8aee7dee96db61b9 Signed-off-by: David Pursehouse --- diff --git a/pom.xml b/pom.xml index 2758844ff0..61869ff43f 100644 --- a/pom.xml +++ b/pom.xml @@ -772,6 +772,9 @@ javac-with-errorprone true + + -Xep:ExpectedExceptionChecker:ERROR + org/eclipse/jgit/transport/InsecureCipherFactory.java