Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 335224

Summary: [JUnit] New JUnit Test Case wizard doesn't store method stub selection state
Product: [Eclipse Project] JDT Reporter: Markus Keller <markus.kell.r>
Component: UIAssignee: Raksha Vasisht <raksha.vasisht>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: daniel_megert
Version: 3.2   
Target Milestone: 3.8 M3   
Hardware: All   
OS: All   
Whiteboard:
Attachments:
Description Flags
Patch none

Description Markus Keller CLA 2011-01-24 13:04:15 EST
HEAD

The New JUnit Test Case wizard doesn't store method stub selection state when you click Finish on the first page. Reason is that NewTestCaseWizardPageOne#saveWidgetValues() is only called on setVisible(false).
Comment 1 Markus Keller CLA 2011-01-24 13:10:36 EST
Raksha, please check whether that was already broken in older releases
If it worked before, find out what change in the platform caused this.
If it was already broken in the beginning, fix it so that the values are stored no matter how the dialog is closed (even when the user pressed Escape).
Comment 2 Dani Megert CLA 2011-04-05 06:11:36 EDT
Broken since 3.2.
Comment 3 Raksha Vasisht CLA 2011-09-27 04:40:52 EDT
Fixed with the attached patch.
Comment 4 Raksha Vasisht CLA 2011-09-27 04:42:20 EDT
Created attachment 204056 [details]
Patch

Patch against HEAD.
Comment 5 Markus Keller CLA 2014-09-16 10:00:07 EDT
The code changes in MethodStubsSelectionButtonGroup were not good. When the user switches between JUnit 3 and 4, we have to uncheck the buttons that get disabled, and we must not create the respective method stubs.

Fixed with http://git.eclipse.org/c/jdt/eclipse.jdt.ui.git/commit/?id=4d1ccf1451cda4f146b93c7bcc05850ab2b01e8a