use of org.eclipse.sapphire.modeling.Status in project liferay-ide by liferay.
the class NewLiferayJSFModuleProjectOpTests method testNewLiferayJSFModuleProjectOpDefaultBuildType.
@Test
public void testNewLiferayJSFModuleProjectOpDefaultBuildType() throws Exception {
NewLiferayJSFModuleProjectOp existedProjectop = NewLiferayJSFModuleProjectOp.TYPE.instantiate();
existedProjectop.setProjectName("Test3");
existedProjectop.setProjectProvider("gradle-jsf");
existedProjectop.setTemplateName("primefaces");
Status exStatus = NewLiferayJSFModuleProjectOpMethods.execute(existedProjectop, ProgressMonitorBridge.create(new NullProgressMonitor()));
assertTrue(exStatus.ok());
IProject existedProject = CoreUtil.getProject(existedProjectop.getProjectName().content());
assertNotNull(existedProject);
NewLiferayJSFModuleProjectOp newBuildTypeop = NewLiferayJSFModuleProjectOp.TYPE.instantiate();
DefaultValueService buildTypeDefaultService = newBuildTypeop.getProjectProvider().service(DefaultValueService.class);
assertEquals(buildTypeDefaultService.value(), "gradle-jsf");
}
use of org.eclipse.sapphire.modeling.Status in project liferay-ide by liferay.
the class NewLiferayJSFModuleProjectOpTests method testMavenRichFacesNewLiferayJSFModuleProjectOp.
@Test
public void testMavenRichFacesNewLiferayJSFModuleProjectOp() throws Exception {
NewLiferayJSFModuleProjectOp existedProjectop = NewLiferayJSFModuleProjectOp.TYPE.instantiate();
existedProjectop.setProjectProvider("maven-jsf");
existedProjectop.setProjectName("Test7");
existedProjectop.setTemplateName("richfaces");
Status exStatus = NewLiferayJSFModuleProjectOpMethods.execute(existedProjectop, ProgressMonitorBridge.create(new NullProgressMonitor()));
assertTrue(exStatus.ok());
IProject existedProject = CoreUtil.getProject(existedProjectop.getProjectName().content());
assertNotNull(existedProject);
}
use of org.eclipse.sapphire.modeling.Status in project liferay-ide by liferay.
the class NewLiferayJSFModuleProjectOpTests method testMavenJSFStandardNewLiferayJSFModuleProjectOp.
@Test
public void testMavenJSFStandardNewLiferayJSFModuleProjectOp() throws Exception {
NewLiferayJSFModuleProjectOp existedProjectop = NewLiferayJSFModuleProjectOp.TYPE.instantiate();
existedProjectop.setProjectProvider("maven-jsf");
existedProjectop.setProjectName("Test11");
existedProjectop.setTemplateName("jsf");
Status exStatus = NewLiferayJSFModuleProjectOpMethods.execute(existedProjectop, ProgressMonitorBridge.create(new NullProgressMonitor()));
assertTrue(exStatus.ok());
IProject existedProject = CoreUtil.getProject(existedProjectop.getProjectName().content());
assertNotNull(existedProject);
}
use of org.eclipse.sapphire.modeling.Status in project liferay-ide by liferay.
the class NewLiferayJSFModuleProjectOpTests method testNewLiferayJSFModuleProjectOpProjectExisted.
@Test
public void testNewLiferayJSFModuleProjectOpProjectExisted() throws Exception {
NewLiferayJSFModuleProjectOp existedProjectop = NewLiferayJSFModuleProjectOp.TYPE.instantiate();
existedProjectop.setProjectProvider("gradle-jsf");
existedProjectop.setProjectName("Test2");
existedProjectop.setTemplateName("richfaces");
Status exStatus = NewLiferayJSFModuleProjectOpMethods.execute(existedProjectop, ProgressMonitorBridge.create(new NullProgressMonitor()));
assertTrue(exStatus.ok());
IProject existedProject = CoreUtil.getProject(existedProjectop.getProjectName().content());
assertNotNull(existedProject);
NewLiferayJSFModuleProjectOp newProjectNameop = NewLiferayJSFModuleProjectOp.TYPE.instantiate();
newProjectNameop.setProjectProvider("gradle-jsf");
newProjectNameop.setProjectName("Test2");
Status projectNameExistedValidationStatus = newProjectNameop.getProjectName().validation();
assertEquals(false, projectNameExistedValidationStatus.ok());
}
use of org.eclipse.sapphire.modeling.Status in project liferay-ide by liferay.
the class NewLiferayJSFModuleProjectOpTests method testMavenLiferayFacesNewLiferayJSFModuleProjectOp.
@Test
public void testMavenLiferayFacesNewLiferayJSFModuleProjectOp() throws Exception {
NewLiferayJSFModuleProjectOp existedProjectop = NewLiferayJSFModuleProjectOp.TYPE.instantiate();
existedProjectop.setProjectProvider("maven-jsf");
existedProjectop.setProjectName("Test9");
existedProjectop.setTemplateName("icefaces");
Status exStatus = NewLiferayJSFModuleProjectOpMethods.execute(existedProjectop, ProgressMonitorBridge.create(new NullProgressMonitor()));
assertTrue(exStatus.ok());
IProject existedProject = CoreUtil.getProject(existedProjectop.getProjectName().content());
assertNotNull(existedProject);
}
Aggregations