Bug 307901 EPartService does not short circuit saveAll(boolean) if 'false' and/or no save handler is provided
The code looks like so... boolean success = true; for (MPart dirtyPart : dirtyParts) { if (!savePart(dirtyPart, false)) { success = false; } } return success; ...the first time a save fails, we should return false immediately.
tests/org.eclipse.e4.ui.tests/src/org/eclipse/e4/ui/tests/application/EPartServiceTest.java
getEngine().createGui(windowA);
		getEngine().createGui(windowB);
		EPartService partServiceA = (EPartService) partFrontA.getContext().get(
				EPartService.class.getName());
		EPartService partServiceB = (EPartService) partFrontB.getContext().get(
				EPartService.class.getName());
		partServiceA.bringToTop(partBackB);
		assertEquals(partStackA.getSelectedElement(), partFrontA);
		assertEquals(partStackB.getSelectedElement(), partFrontB);
		partServiceB.bringToTop(partBackA);
		assertEquals(partStackA.getSelectedElement(), partFrontA);
		assertEquals(partStackB.getSelectedElement(), partFrontB);
		partServiceA.bringToTop(partBackA);
		assertEquals(partStackA.getSelectedElement(), partBackA);
		assertEquals(partStackB.getSelectedElement(), partFrontB);
		partServiceB.bringToTop(partBackB);
		assertEquals(partStackA.getSelectedElement(), partBackA);
		assertEquals(partStackB.getSelectedElement(), partBackB);
	}
	public void testBringToTop_ActivationChanges() {
		MApplication application = MApplicationFactory.eINSTANCE
				.createApplication();
		MWindow window = MApplicationFactory.eINSTANCE.createWindow();
		application.getChildren().add(window);
		MPartStack partStackA = MApplicationFactory.eINSTANCE.createPartStack();
		MPart partFrontA = MApplicationFactory.eINSTANCE.createPart();
		MPart partBackA = MApplicationFactory.eINSTANCE.createPart();
		partStackA.getChildren().add(partFrontA);
		partStackA.getChildren().add(partBackA);
		window.getChildren().add(partStackA);