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
testHidePart_Tagged(true);
	}
	public void testHidePart_Tagged_False() {
		testHidePart_Tagged(false);
	}
	public void testGetDirtyParts() {
		MApplication application = createApplication(1, new String[1][0]);
		MWindow window = application.getChildren().get(0);
		getEngine().createGui(window);
		EPartService partService = (EPartService) window.getContext().get(
				EPartService.class.getName());
		Collection<MPart> dirtyParts = partService.getDirtyParts();
		assertNotNull(dirtyParts);
		assertEquals(0, dirtyParts.size());
	}
	public void testGetDirtyParts2() {
		MApplication application = createApplication("partId");
		MWindow window = application.getChildren().get(0);
		getEngine().createGui(window);
		EPartService partService = (EPartService) window.getContext().get(
				EPartService.class.getName());
		Collection<MPart> dirtyParts = partService.getDirtyParts();
		assertNotNull(dirtyParts);
		assertEquals(0, dirtyParts.size());
	}
	private void testGetDirtyParts3(boolean before, boolean after) {
		MApplication application = MApplicationFactory.eINSTANCE
				.createApplication();
		MWindow window = MApplicationFactory.eINSTANCE.createWindow();
		application.getChildren().add(window);