Minimal cleanup

This commit is contained in:
René Pfeuffer
2019-03-29 13:25:22 +01:00
parent 9833bfd34d
commit bf84037019
3 changed files with 7 additions and 8 deletions

View File

@@ -127,7 +127,8 @@ public class HgHookChangesetProvider implements HookChangesetProvider
boolean pending = type == RepositoryHookType.PRE_RECEIVE;
// TODO get repository encoding
return HgUtil.open(handler, hookManager, repositoryDirectory, null, pending);
return HgUtil.open(handler, hookManager, repositoryDirectory, null,
pending);
}
//~--- fields ---------------------------------------------------------------

View File

@@ -47,8 +47,8 @@ import sonia.scm.repository.Repository;
public class HgRepositoryServiceResolver implements RepositoryServiceResolver
{
private final HgRepositoryHandler handler;
private final HgHookManager hookManager;
private HgRepositoryHandler handler;
private HgHookManager hookManager;
@Inject
public HgRepositoryServiceResolver(HgRepositoryHandler handler,

View File

@@ -102,8 +102,6 @@ public class BranchRootResourceTest extends RepositoryTestBase {
branchRootResource = new BranchRootResource(serviceFactory, branchToDtoMapper, branchCollectionToDtoMapper, changesetCollectionToDtoMapper, resourceLinks);
super.branchRootResource = Providers.of(branchRootResource);
dispatcher = DispatcherMock.createDispatcher(getRepositoryRootResource());
// dispatcher.getRegistry().addSingletonResource(getRepositoryRootResource());
when(serviceFactory.create(new NamespaceAndName("space", "repo"))).thenReturn(service);
when(serviceFactory.create(any(Repository.class))).thenReturn(service);
when(service.getRepository()).thenReturn(new Repository("repoId", "git", "space", "repo"));