FileResolverTest#testNotAGitRepository: Fail when exception is not thrown

Error Prone reports:

  Not calling fail() when expecting an exception masks bugs

See https://errorprone.info/bugpattern/MissingFail

Change-Id: I9ac844aa6c5a620d9b5d21d2e242347b3788b96a
Signed-off-by: David Pursehouse <david.pursehouse@gmail.com>
This commit is contained in:
David Pursehouse 2018-09-29 12:45:20 +09:00
parent 1bb430dc21
commit 873b0b7754
1 changed files with 1 additions and 0 deletions

View File

@ -147,6 +147,7 @@ public void testNotAGitRepository() throws IOException,
try {
resolver.open(null, name);
fail("opened non-git repository");
} catch (RepositoryNotFoundException e) {
assertEquals("repository not found: " + name, e.getMessage());