LocalDiskRepositoryTestCase: Clarify semantics of repository creation methods
Several of the utility methods create a Repository without setting the 'autoClose' flag, which means that the caller is responsible for closing it. Update the Javadoc to explicitly mention this. Change-Id: I2410dd8d230cd4519f756c38b17141d0daa6c314 Signed-off-by: David Pursehouse <david.pursehouse@gmail.com>
This commit is contained in:
parent
9c2ef2d71e
commit
ee32ca226e
|
@ -366,7 +366,9 @@ public static String indexState(Repository repo, int includedOptions)
|
||||||
/**
|
/**
|
||||||
* Creates a new empty bare repository.
|
* Creates a new empty bare repository.
|
||||||
*
|
*
|
||||||
* @return the newly created repository, opened for access
|
* @return the newly created bare repository, opened for access. The
|
||||||
|
* repository will not be closed in {@link #tearDown()}; the caller
|
||||||
|
* is responsible for closing it.
|
||||||
* @throws IOException
|
* @throws IOException
|
||||||
* the repository could not be created in the temporary area
|
* the repository could not be created in the temporary area
|
||||||
*/
|
*/
|
||||||
|
@ -377,7 +379,9 @@ protected FileRepository createBareRepository() throws IOException {
|
||||||
/**
|
/**
|
||||||
* Creates a new empty repository within a new empty working directory.
|
* Creates a new empty repository within a new empty working directory.
|
||||||
*
|
*
|
||||||
* @return the newly created repository, opened for access
|
* @return the newly created repository, opened for access. The repository
|
||||||
|
* will not be closed in {@link #tearDown()}; the caller is
|
||||||
|
* responsible for closing it.
|
||||||
* @throws IOException
|
* @throws IOException
|
||||||
* the repository could not be created in the temporary area
|
* the repository could not be created in the temporary area
|
||||||
*/
|
*/
|
||||||
|
@ -391,7 +395,9 @@ protected FileRepository createWorkRepository() throws IOException {
|
||||||
* @param bare
|
* @param bare
|
||||||
* true to create a bare repository; false to make a repository
|
* true to create a bare repository; false to make a repository
|
||||||
* within its working directory
|
* within its working directory
|
||||||
* @return the newly created repository, opened for access
|
* @return the newly created repository, opened for access. The repository
|
||||||
|
* will not be closed in {@link #tearDown()}; the caller is
|
||||||
|
* responsible for closing it.
|
||||||
* @throws IOException
|
* @throws IOException
|
||||||
* the repository could not be created in the temporary area
|
* the repository could not be created in the temporary area
|
||||||
* @since 5.3
|
* @since 5.3
|
||||||
|
|
Loading…
Reference in New Issue