Bug 328946 Part activation history may return incorrect candidate if no placeholders could be found in a perspective
1. Window > Open Perspective > Other... > CVS Repository Exploring 2. Hide the 'CVS Repositories' view. 3. The 'History' view should become active, it is not.
tests/org.eclipse.e4.ui.tests/src/org/eclipse/e4/ui/tests/application/EPartServiceTest.java
MPartStack partStackB = BasicFactoryImpl.eINSTANCE.createPartStack();
		perspectiveB.getChildren().add(partStackB);
		perspectiveB.setSelectedElement(partStackB);
		MPlaceholder partPlaceholderA2 = AdvancedFactoryImpl.eINSTANCE
				.createPlaceholder();
		partPlaceholderA2.setRef(partA);
		partStackB.getChildren().add(partPlaceholderA2);
		partStackB.setSelectedElement(partPlaceholderA2);
		MPlaceholder partPlaceholderB2 = AdvancedFactoryImpl.eINSTANCE
				.createPlaceholder();
		partPlaceholderB2.setRef(partB);
		partStackB.getChildren().add(partPlaceholderB2);
		initialize(applicationContext, application);
		getEngine().createGui(window);
		EPartService partService = window.getContext().get(EPartService.class);
		partService.activate(partB);
		partService.switchPerspective(perspectiveB);
		assertEquals(
				"partB is in both perspectives, but since partB is obscured by partA, partA should be the active part",
				partA, partService.getActivePart());
		partService.hidePart(partB);
		assertEquals("partA should still be the active part", partA,
				partService.getActivePart());
		partService.switchPerspective(perspectiveA);
		assertEquals(
				"partB is the only part in perspectiveA, thus, it should be the active part",
				partB, partService.getActivePart());
		partService.switchPerspective(perspectiveB);
		assertEquals(
				"partA should be the only part that's being shown in perspectiveB, thus, it should be the active part",