Bug 98472 New project wizard: second page remove from class path should ask for removal of folder when linked
RC1 - create a new project - switch to the second page - link in additional source observe: there is no way to unlink the addtional source We should offer to unlink the folder when the folder is removed from the build path again.
org.eclipse.jdt.ui.tests/ui/org/eclipse/jdt/ui/tests/dialogs/NewProjectWizardTest.java
int after= inclusionPatterns.length;
        assertTrue(contains(new Path(folder.getName()), inclusionPatterns, null));
        assertTrue(before + 1 == after);
        return cpFolder;
    }
    
    protected IFolder excludePackage() throws JavaModelException, CoreException, InvocationTargetException, InterruptedException {
        IPackageFragmentRoot root= addToClasspath(new Path(fNormalFolder));
        IFolder cpFolder= getFolderHandle(new Path(fNormalFolder));
        IFolder folder= getFolderHandle(cpFolder.getProjectRelativePath().append(fSubFolder));
        IPackageFragment fragment= root.getPackageFragment(folder.getName());
        
        IClasspathEntry entry= root.getRawClasspathEntry();
        int nrExcluded= entry.getExclusionPatterns().length;
        executeOperation(IClasspathInformationProvider.EXCLUDE, fragment, null, null, null, null);
        
        entry= root.getRawClasspathEntry();
        IPath[] exclusionPatterns= entry.getExclusionPatterns();
        assertTrue(nrExcluded + 1 == exclusionPatterns.length);
        assertTrue(contains(new Path(fragment.getElementName()), exclusionPatterns, null));
        return cpFolder;
    }
    
    protected IFolder getFolderHandle(IPath path) {
        IFolder folder= fProject.getProject().getFolder(path);
        try {
            if (!folder.exists())
                folder.create(true, false, null);
        } catch (CoreException e) {
        }