Bug 296796 MWindow name changes are not reflected in a shell
tests/org.eclipse.e4.ui.tests/src/org/eclipse/e4/ui/tests/workbench/MWindowTest.java
MPartStack stack = MApplicationFactory.eINSTANCE.createPartStack();
		sash.getChildren().add(stack);
		MPart contributedPart = MApplicationFactory.eINSTANCE.createPart();
		stack.getChildren().add(contributedPart);
		contributedPart.setName("Sample View");
		contributedPart
				.setURI("platform:/plugin/org.eclipse.e4.ui.tests/org.eclipse.e4.ui.tests.workbench.SampleView");
		return window;
	}
	private MWindow createWindowWithOneViewAndMenu() {
		final MWindow window = createWindowWithOneView();
		final MMenu menuBar = MApplicationFactory.eINSTANCE.createMenu();
		window.setMainMenu(menuBar);
		final MMenuItem fileItem = MApplicationFactory.eINSTANCE
				.createMenuItem();
		fileItem.setName("File");
		fileItem.setId("file");
		menuBar.getChildren().add(fileItem);
		final MMenuItem item1 = MApplicationFactory.eINSTANCE.createMenuItem();
		item1.setId("item1");
		item1.setName("item1");
		fileItem.getChildren().add(item1);
		final MMenuItem item2 = MApplicationFactory.eINSTANCE.createMenuItem();
		item2.setId("item2");
		item2.setName("item2");
		fileItem.getChildren().add(item2);
		return window;
	}
}