Merge change 1739 into donut

* changes:
  Fix an NPE in the New Project Wizard when no test project is specified on the second NPW page.
This commit is contained in:
Android (Google) Code Review
2009-05-14 19:36:03 -07:00

View File

@@ -352,9 +352,6 @@ public class NewProjectWizard extends Wizard implements INewWizard {
}
final ProjectInfo testData = collectTestPageInfo();
if (mTestPage != null && testData == null) {
return false;
}
// Create a monitored operation to create the actual project
WorkspaceModifyOperation op = new WorkspaceModifyOperation() {
@@ -439,9 +436,12 @@ public class NewProjectWizard extends Wizard implements INewWizard {
if (mTestPage == null) {
return null;
}
TestInfo info = mTestPage.getTestInfo();
if (!info.getCreateTestProject()) {
return null;
}
IWorkspace workspace = ResourcesPlugin.getWorkspace();
final IProject project = workspace.getRoot().getProject(info.getProjectName());
final IProjectDescription description = workspace.newProjectDescription(project.getName());