mirror of
https://github.com/scm-manager/scm-manager.git
synced 2025-11-14 17:26:22 +01:00
remove old hook system in favor of event bus
This commit is contained in:
@@ -35,8 +35,6 @@ package sonia.scm.repository;
|
||||
|
||||
//~--- non-JDK imports --------------------------------------------------------
|
||||
|
||||
import com.google.inject.Provider;
|
||||
|
||||
import org.junit.Test;
|
||||
|
||||
import sonia.scm.Type;
|
||||
@@ -48,8 +46,6 @@ import sonia.scm.store.StoreFactory;
|
||||
|
||||
import static org.junit.Assert.*;
|
||||
|
||||
import static org.mockito.Mockito.*;
|
||||
|
||||
//~--- JDK imports ------------------------------------------------------------
|
||||
|
||||
import java.io.IOException;
|
||||
@@ -140,10 +136,6 @@ public class DefaultRepositoryManagerTest extends RepositoryManagerTestBase
|
||||
}
|
||||
});
|
||||
|
||||
Provider<Set<RepositoryHook>> hookProvider = mock(Provider.class);
|
||||
|
||||
when(hookProvider.get()).thenReturn(new HashSet<RepositoryHook>());
|
||||
|
||||
XmlRepositoryDAO repositoryDAO = new XmlRepositoryDAO(factory);
|
||||
|
||||
ScmConfiguration configuration = new ScmConfiguration();
|
||||
@@ -151,28 +143,7 @@ public class DefaultRepositoryManagerTest extends RepositoryManagerTestBase
|
||||
configuration.setEnableRepositoryArchive(archiveEnabled);
|
||||
|
||||
return new DefaultRepositoryManager(configuration, contextProvider,
|
||||
new DefaultKeyGenerator(), repositoryDAO, handlerSet,
|
||||
hookProvider, createEmptyPreProcessorUtil());
|
||||
}
|
||||
|
||||
/**
|
||||
* Method description
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
private PreProcessorUtil createEmptyPreProcessorUtil()
|
||||
{
|
||||
//J-
|
||||
return new PreProcessorUtil(
|
||||
new HashSet<ChangesetPreProcessor>(),
|
||||
new HashSet<ChangesetPreProcessorFactory>(),
|
||||
new HashSet<FileObjectPreProcessor>(),
|
||||
new HashSet<FileObjectPreProcessorFactory>(),
|
||||
new HashSet<BlameLinePreProcessor>(),
|
||||
new HashSet<BlameLinePreProcessorFactory>()
|
||||
);
|
||||
//J+
|
||||
new DefaultKeyGenerator(), repositoryDAO, handlerSet);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user