Bug 18496 Launch config: getting asked to save changes when there where no changes
1) execute Run As>JUnit test on a test case 2) open the launch config dialog -> the newly created config is selected 3) click on another config ->you get prompted whether you want to save changes Verified that the same attributes are set. What is special about the JUnit launch config is that the tab group initializes the default run perspective to "null", i.e. no change. However, when doing the compare only values supplied by the tabs are taken into consideration. See LaunchConfigurationDialog.updateWorkingCopyFromPages(); The defaults set by the tabgroup itself are not considered. Hence there is a difference. The launch configs compared are (without the qualifcation) MAIN_TYPE=junit.samples.VectorTest, PROJECT_ATTR=JUnit, KEEPRUNNING_ATTR=false, source_locator_id=org.eclipse.jdt.debug.ui.javaSourceLocator, target_debug_perspective=perspective_default} MAIN_TYPE=junit.samples.VectorTest, KEEPRUNNING_ATTR=false, PROJECT_ATTR=JUnit, target_run_perspective=perspective_none, source_locator_id=org.eclipse.jdt.debug.ui.javaSourceLocator, target_debug_perspective=perspective_default As you can see the run perspective is missing in one config.
org.eclipse.jdt.junit/src/org/eclipse/jdt/internal/junit/launcher/JUnitLaunchShortcut.java
*/
	protected ILaunchConfiguration chooseConfiguration(List configList, String mode) {
		IDebugModelPresentation labelProvider = DebugUITools.newDebugModelPresentation();
		ElementListSelectionDialog dialog= new ElementListSelectionDialog(getShell(), labelProvider);
		dialog.setElements(configList.toArray());
		dialog.setTitle(JUnitMessages.getString("LaunchTestAction.message.selectConfiguration")); 
		if (mode.equals(ILaunchManager.DEBUG_MODE)) {
			dialog.setMessage(JUnitMessages.getString("LaunchTestAction.message.selectDebugConfiguration")); 
		} else {
			dialog.setMessage(JUnitMessages.getString("LaunchTestAction.message.selectRunConfiguration")); 
		}
		dialog.setMultipleSelection(false);
		int result= dialog.open();
		labelProvider.dispose();
		if (result == dialog.OK) {
			return (ILaunchConfiguration)dialog.getFirstResult();
		}
		return null;		
	}
	
	/**
	 * Create & return a new configuration based on the specified <code>IType</code>.
	 */
	protected ILaunchConfiguration createConfiguration(IType type) {
		ILaunchConfiguration config = null;
		try {
			ILaunchConfigurationType configType= getJUnitLaunchConfigType();
			ILaunchConfigurationWorkingCopy wc = configType.newInstance(null, getLaunchManager().generateUniqueLaunchConfigurationNameFrom(type.getElementName())); 
			wc.setAttribute(IJavaLaunchConfigurationConstants.ATTR_MAIN_TYPE_NAME, type.getFullyQualifiedName());
			wc.setAttribute(IJavaLaunchConfigurationConstants.ATTR_PROJECT_NAME, type.getJavaProject().getElementName());