Bug 159897 - [JUnit] org.eclipse.jdt.internal.junit.ui.CompareResultDialog settings not saved in dialog_settings.xml
Summary: [JUnit] org.eclipse.jdt.internal.junit.ui.CompareResultDialog settings not sa...
Status: RESOLVED INVALID
Alias: None
Product: JDT
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 3.2   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: JDT-UI-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords: needinfo
Depends on:
Blocks:
 
Reported: 2006-10-05 11:46 EDT by Deryck Brown CLA
Modified: 2009-08-30 02:05 EDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Deryck Brown CLA 2006-10-05 11:46:06 EDT
The settings for the org.eclipse.jdt.junit.CompareResultDialog are missing from the org.eclipse.jdt.junit/dialog_settings.xml in the user's workspace resulting in the dialog window being disabled in the Eclipse user interface.

The missing <section> from the workspace of a previous Eclipse version reads:

<section name="org.eclipse.jdt.internal.junit.ui.CompareResultDialog">
		<item key="DIALOG_X_ORIGIN" value="334"/>
		<item key="DIALOG_HEIGHT" value="253"/>
		<item key="DIALOG_FONT_NAME" value="1|Tahoma|8|0|WINDOWS|1|-11|0|0|0|400|0|0|0|1|0|0|0|0|Tahoma"/>
		<item key="DIALOG_Y_ORIGIN" value="334"/>
		<item key="DIALOG_WIDTH" value="620"/>
	</section>

This entry is missing from a new workspace created under Eclipse v3.2.
Comment 1 Olivier Thomann CLA 2006-10-05 11:50:29 EDT
Moving to JDT/UI
Comment 2 Martin Aeschlimann CLA 2006-10-06 13:04:33 EDT
A new workspace wouldn't have this setting, and the dialog should show up anyways. This information just stores the last recently used size.
What effect did you see?
Note that this dialog show up when you double click on an string assertion failure in the JUnit view.
Comment 3 Deryck Brown CLA 2006-10-06 13:43:26 EDT
Clean install of v3.2 running for students taking a lab on using JUnit with Eclipse. Run unit tests with comparison failures. Double-click on error does not bring up comparison results dialog and the button at the edge of the JUnit results is also disabled.

There appears to be no preferences that alters this behaviour, and the only difference I can see in the created workspace is this missing setting.

Deryck
Comment 4 Martin Aeschlimann CLA 2006-10-09 04:50:18 EDT
And this is a string comparison failure? (the dialog only shows up on these...)
junit.framework.ComparisonFailure: expected:<Hell[o]> but was:<Hel[lO]>
	at junit.framework.Assert.assertEquals(Assert.java:81)
	at junit.framework.Assert.assertEquals(Assert.java:87)
	at p.MyTest.testFoo(MyTest.java:6)
	
public class MyTest extends TestCase {
        public void testFoo() {
        	assertEquals("Hello", "HellO");
        }
}
Comment 5 Deryck Brown CLA 2006-10-09 05:24:19 EDT
Specifically, this was a JUnit 4 test case to test the toString method in a simple class representing a Playing Card. The test should have been equivalent to the call:

    assertEquals("AC", "2D");

In my installation of Eclipse, everything worked as expected including the ability to display the result comparison dialog. For the students (and at least one other member of staff), who have clean installs of v3.2 and have never used another copy of Eclipse before, they get the ComparisonFailure but cannot view the result comparison dialog.
Comment 6 Martin Aeschlimann CLA 2006-10-09 08:47:11 EDT
I have no idea what this could be. I can't reproduce and I would need this to debug the problem.
Comment 7 Martin Aeschlimann CLA 2006-10-16 05:26:30 EDT
setting to remind until I can reproduce or have an idea what the problem could be
Comment 8 Denis Roy CLA 2009-08-30 02:05:18 EDT
As of now 'LATER' and 'REMIND' resolutions are no longer supported.
Please reopen this bug if it is still valid for you.