use of org.sonar.api.batch.bootstrap.ProjectReactor in project sonarqube by SonarSource.
the class ProjectReactorValidatorTest method fail_with_only_digits.
@Test
public void fail_with_only_digits() {
ProjectReactor reactor = createProjectReactor("12345");
thrown.expect(MessageException.class);
thrown.expectMessage("\"12345\" is not a valid project or module key");
validator.validate(reactor);
}
use of org.sonar.api.batch.bootstrap.ProjectReactor in project sonarqube by SonarSource.
the class ProjectReactorValidatorTest method createProjectReactor.
private ProjectReactor createProjectReactor(String projectKey, String branch) {
ProjectDefinition def = ProjectDefinition.create().setProperty(CoreProperties.PROJECT_KEY_PROPERTY, projectKey).setProperty(CoreProperties.PROJECT_BRANCH_PROPERTY, branch);
ProjectReactor reactor = new ProjectReactor(def);
settings.setProperty(CoreProperties.PROJECT_BRANCH_PROPERTY, branch);
return reactor;
}
Aggregations