use of org.sonar.core.platform.ComponentContainer in project sonarqube by SonarSource.
the class ReportComputationStepsTest method instances_throws_ISE_if_container_does_not_have_any_step.
@Test
public void instances_throws_ISE_if_container_does_not_have_any_step() throws Exception {
expectedException.expect(IllegalStateException.class);
expectedException.expectMessage("Component not found: " + ExtractReportStep.class);
TaskContainerImpl computeEngineContainer = new TaskContainerImpl(new ComponentContainer(), new ContainerPopulator<TaskContainer>() {
@Override
public void populateContainer(TaskContainer container) {
// do nothing
}
});
Lists.newArrayList(new ReportComputationSteps(computeEngineContainer).instances());
}
use of org.sonar.core.platform.ComponentContainer in project sonarqube by SonarSource.
the class EsTester method before.
@Override
protected void before() throws Throwable {
truncateIndices();
if (!indexDefinitions.isEmpty()) {
container = new ComponentContainer();
container.addSingleton(new MapSettings());
container.addSingletons(indexDefinitions);
container.addSingleton(client);
container.addSingleton(IndexDefinitions.class);
container.addSingleton(IndexCreator.class);
container.startComponents();
}
}
use of org.sonar.core.platform.ComponentContainer in project sonarqube by SonarSource.
the class ProjectsEsModuleTest method verify_count_of_added_components.
@Test
public void verify_count_of_added_components() {
ComponentContainer container = new ComponentContainer();
new ProjectsEsModule().configure(container);
assertThat(container.size()).isEqualTo(3 + 2);
}
use of org.sonar.core.platform.ComponentContainer in project sonarqube by SonarSource.
the class LicensesWsModuleTest method verify_count_of_added_components.
@Test
public void verify_count_of_added_components() {
ComponentContainer container = new ComponentContainer();
new LicensesWsModule().configure(container);
assertThat(container.size()).isEqualTo(2 + 2);
}
use of org.sonar.core.platform.ComponentContainer in project sonarqube by SonarSource.
the class NotificationModuleTest method verify_count_of_added_components.
@Test
public void verify_count_of_added_components() {
ComponentContainer container = new ComponentContainer();
new NotificationModule().configure(container);
assertThat(container.size()).isEqualTo(12 + 2);
}
Aggregations