mirror of
https://github.com/scm-manager/scm-manager.git
synced 2025-11-06 21:45:43 +01:00
Make type optional
This commit is contained in:
@@ -76,7 +76,7 @@ public class LfsBlobStoreFactory {
|
||||
*/
|
||||
@SuppressWarnings("unchecked")
|
||||
public BlobStore getLfsBlobStore(Repository repository) {
|
||||
return blobStoreFactory.forType(String.class)
|
||||
return blobStoreFactory
|
||||
.withName(repository.getId() + GIT_LFS_REPOSITORY_POSTFIX)
|
||||
.forRepository(repository)
|
||||
.build();
|
||||
|
||||
@@ -86,7 +86,7 @@ public class GitRepositoryHandlerTest extends SimpleRepositoryHandlerTestBase {
|
||||
|
||||
@Before
|
||||
public void initFactory() {
|
||||
when(factory.forType(any())).thenCallRealMethod();
|
||||
when(factory.withName(any())).thenCallRealMethod();
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -63,7 +63,7 @@ public class LfsBlobStoreFactoryTest {
|
||||
|
||||
@Test
|
||||
public void getBlobStore() {
|
||||
when(blobStoreFactory.forType(any())).thenCallRealMethod();
|
||||
when(blobStoreFactory.withName(any())).thenCallRealMethod();
|
||||
Repository repository = new Repository("the-id", "GIT", "space", "the-name");
|
||||
lfsBlobStoreFactory.getLfsBlobStore(repository);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user