aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Pursehouse <david.pursehouse@gmail.com>2018-09-29 13:02:26 +0900
committerDavid Pursehouse <david.pursehouse@gmail.com>2018-09-29 13:02:26 +0900
commit302717c30b2bfd9b912b6133a1371288c6c3b0cd (patch)
tree7cf66536c495fc1a20f9b7012d64b90004f68b32
parentf02844caaefcb7450cde2e3ff64485eb87eef6be (diff)
downloadjgit-302717c30b2bfd9b912b6133a1371288c6c3b0cd.tar.gz
jgit-302717c30b2bfd9b912b6133a1371288c6c3b0cd.zip
DirCacheBuilderTest#testBuildRejectsUnsetFileMode: Add missing fail()
Error Prone reports: Not calling fail() when expecting an exception masks bugs See https://errorprone.info/bugpattern/MissingFail Change-Id: Ic89f9daef3c31bfbfd1f3c003cb90a373cd74847 Signed-off-by: David Pursehouse <david.pursehouse@gmail.com>
-rw-r--r--org.eclipse.jgit.test/tst/org/eclipse/jgit/dircache/DirCacheBuilderTest.java1
1 files changed, 1 insertions, 0 deletions
diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/dircache/DirCacheBuilderTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/dircache/DirCacheBuilderTest.java
index d12f302dae..b6291bfca4 100644
--- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/dircache/DirCacheBuilderTest.java
+++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/dircache/DirCacheBuilderTest.java
@@ -89,6 +89,7 @@ public class DirCacheBuilderTest extends RepositoryTestCase {
assertEquals(0, e.getRawMode());
try {
b.add(e);
+ fail("did not reject unset file mode");
} catch (IllegalArgumentException err) {
assertEquals("FileMode not set for path a", err.getMessage());
}