Bug 327765 EPartService will hide a part of another perspective
tests/org.eclipse.e4.ui.tests/src/org/eclipse/e4/ui/tests/application/EPartServiceTest.java
partPlaceholderB2.setRef(partB);
		perspectiveB.getChildren().add(partPlaceholderB2);
		initialize(applicationContext, application);
		getEngine().createGui(window1);
		getEngine().createGui(window2);
		assertEquals(window1.getContext(), application.getContext()
				.getActiveChild());
		assertEquals(perspectiveA.getContext(), window2.getContext()
				.getActiveChild());
		EPartService partService = window2.getContext().get(EPartService.class);
		partService.switchPerspective(perspectiveB);
		assertEquals(window1.getContext(), application.getContext()
				.getActiveChild());
		assertEquals(perspectiveB.getContext(), window2.getContext()
				.getActiveChild());
	}
	/**
	 * Tests that a perspective will automatically select another part as the
	 * active part after the originally active part that's being shown across
	 * multiple perspectives has been removed.
	 */
	public void testSwitchPerspective05() {
		MApplication application = ApplicationFactoryImpl.eINSTANCE
				.createApplication();
		MWindow window1 = BasicFactoryImpl.eINSTANCE.createWindow();
		application.getChildren().add(window1);
		application.setSelectedElement(window1);
		MWindow window2 = BasicFactoryImpl.eINSTANCE.createWindow();
		application.getChildren().add(window2);
		MArea area = AdvancedFactoryImpl.eINSTANCE.createArea();