Browse Source

LocalDiskRepositoryTestCase: Only add to toClose through access method

Only using the access method means we only have one place where the
toClose set is modified, making it easier to debug either by adding
log statements or by setting a breakpoint.

Change-Id: I4f9f1774d5f2e10bcab381edfd84bb6ee0499a11
Signed-off-by: David Pursehouse <david.pursehouse@gmail.com>
tags/v4.7.0.201704051617-r
David Pursehouse 7 years ago
parent
commit
5d0ca36d39

+ 1
- 1
org.eclipse.jgit.junit/src/org/eclipse/jgit/junit/LocalDiskRepositoryTestCase.java View File

@@ -364,7 +364,7 @@ public abstract class LocalDiskRepositoryTestCase {
FileRepository db = new FileRepository(gitdir);
assertFalse(gitdir.exists());
db.create(bare);
toClose.add(db);
addRepoToClose(db);
return db;
}


Loading…
Cancel
Save