@Before
public void prepare()
{
Injector injector = injectorInst.get();
when(serviceLoader.onlyOne(DeploymentScenarioGenerator.class, AnnotationDeploymentScenarioGenerator.class))
.thenReturn(new AnnotationDeploymentScenarioGenerator());
when(serviceLoader.onlyOne(eq(DeployableContainer.class))).thenReturn(deployableContainer);
when(deployableContainer.getDefaultProtocol()).thenReturn(new ProtocolDescription(PROTOCOL_NAME_1));
when(serviceLoader.all(eq(AuxiliaryArchiveAppender.class)))
.thenReturn(create(AuxiliaryArchiveAppender.class, injector.inject(new TestAuxiliaryArchiveAppender())));
when(serviceLoader.all(eq(AuxiliaryArchiveProcessor.class)))
.thenReturn(create(AuxiliaryArchiveProcessor.class, injector.inject(new TestAuxiliaryArchiveProcessor())));
when(serviceLoader.all(eq(ApplicationArchiveProcessor.class)))
.thenReturn(create(ApplicationArchiveProcessor.class, injector.inject(new TestApplicationArchiveAppender())));
containerRegistry = new LocalContainerRegistry(injector);
protocolRegistry = new ProtocolRegistry();
bind(ApplicationScoped.class, ServiceLoader.class, serviceLoader);