use of org.opensolaris.opengrok.configuration.Project in project OpenGrok by OpenGrok.
the class ProjectHelperTest method testGetAllowedProjects.
/**
* Test of getProjects method, of class ProjectHelper.
*/
@Test
public void testGetAllowedProjects() {
Set<Project> result = helper.getProjects();
Assert.assertEquals(2, result.size());
for (Project p : result) {
Assert.assertTrue(p.getName().startsWith("allowed_"));
}
}
use of org.opensolaris.opengrok.configuration.Project in project OpenGrok by OpenGrok.
the class ProjectHelperTest method testGetAllProjects.
/**
* Test of getAllProjects method, of class ProjectHelper.
*/
@Test
public void testGetAllProjects() {
Set<Project> result = helper.getAllProjects();
Assert.assertEquals(12, result.size());
for (Project p : result) {
Assert.assertTrue(p.getName().startsWith("allowed_"));
}
}
use of org.opensolaris.opengrok.configuration.Project in project OpenGrok by OpenGrok.
the class ProjectHelperTest method testGetUngroupedProjects.
/**
* Test of getUngroupedProjects method, of class ProjectHelper.
*/
@Test
public void testGetUngroupedProjects() {
Set<Project> result = helper.getUngroupedProjects();
Assert.assertEquals(2, result.size());
for (Project p : result) {
Assert.assertTrue(p.getName().startsWith("allowed_"));
}
}
use of org.opensolaris.opengrok.configuration.Project in project OpenGrok by OpenGrok.
the class ProjectHelperTest method testGetProjectsAllowedGroup.
/**
* Test of getProjects method, of class ProjectHelper.
*/
@Test
public void testGetProjectsAllowedGroup() {
for (Group g : RuntimeEnvironment.getInstance().getGroups()) {
if (g.getName().startsWith("allowed_group_0")) {
Set<Project> result = helper.getProjects(g);
Assert.assertEquals(2, result.size());
for (Project p : result) {
Assert.assertTrue(p.getName().startsWith("allowed_"));
}
}
}
}
use of org.opensolaris.opengrok.configuration.Project in project OpenGrok by OpenGrok.
the class ProjectHelperTest method testGetGroupedProjects.
/**
* Test of getGroupedProjects method, of class ProjectHelper.
*/
@Test
public void testGetGroupedProjects() {
Set<Project> result = helper.getGroupedProjects();
Assert.assertEquals(4, result.size());
for (Project p : result) {
Assert.assertTrue(p.getName().startsWith("allowed_"));
}
}
Aggregations