use of org.hibernate.eclipse.console.test.project.ConfigurableTestProject in project jbosstools-hibernate by jbosstools.
the class MappingTestsBase method setUp.
protected void setUp() throws Exception {
super.setUp();
// $NON-NLS-1$
testProject = new ConfigurableTestProject("JUnitTestProj" + System.currentTimeMillis());
consoleConfigName = testProject.getIProject().getName();
testPackage = null;
PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage().setPerspective(// $NON-NLS-1$
PlatformUI.getWorkbench().getPerspectiveRegistry().findPerspectiveWithId("org.eclipse.ui.resourcePerspective"));
IPackagesViewPart packageExplorer = null;
try {
packageExplorer = (IPackagesViewPart) PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage().showView(JavaUI.ID_PACKAGES);
} catch (PartInitException e) {
throw new RuntimeException(e);
}
packageExplorer.selectAndReveal(testProject.getIJavaProject());
// PlatformUI.getWorkbench()
// .getActiveWorkbenchWindow().getActivePage().setPerspective(
// PlatformUI.getWorkbench().getPerspectiveRegistry().findPerspectiveWithId(HibernateConsolePerspectiveFactory.ID_CONSOLE_PERSPECTIVE));
setUpConsoleConfig();
ProjectUtils.toggleHibernateOnProject(testProject.getIProject(), true, consoleConfigName);
testProject.fullBuild();
}
Aggregations