Bug 329482 Uninstantiated part may be rendered when closing another part in the same stack
1. Activate the 'Javadoc' view. 2. Activate the 'Package Explorer' view. 3. Shutdown. 4. Restart. 5. Ctrl+3 > Properties 6. Hide the 'Properties' view. 7. Now the 'Problems' view is the selected element. It should be the 'Javadoc' view.
tests/org.eclipse.e4.ui.tests/src/org/eclipse/e4/ui/tests/application/EPartServiceTest.java
final MPart saveablePart = createSaveablePart(window, beforeDirty[0]);
		final MPart saveablePart2 = createSaveablePart(window, beforeDirty[1]);
		
		initialize(applicationContext, application);
		getEngine().createGui(window);
		ClientEditor editor = (ClientEditor) saveablePart.getObject();
		editor.setThrowException(throwException[0]);
		ClientEditor editor2 = (ClientEditor) saveablePart2.getObject();
		editor2.setThrowException(throwException[1]);
		window.getContext().set(ISaveHandler.class.getName(),
				new ISaveHandler() {
					public Save[] promptToSave(Collection<MPart> saveableParts) {
						int index = 0;
						Save[] prompt = new Save[saveableParts.size()];
						Iterator<MPart> it = saveableParts.iterator();
						while (it.hasNext()) {
							prompt[index] = prompt(returnValues, it.next(),
									saveablePart);
							index++;
						}
						return prompt;
					}
					public Save promptToSave(MPart saveablePart) {
						return null;
					}
				});
		EPartService partService = (EPartService) window.getContext().get(
				EPartService.class.getName());
		assertEquals(success, partService.saveAll(confirm));
		assertEquals(afterDirty[0], saveablePart.isDirty());