Bug 112556 - [JUnit] 'Stop JUnit test run' does not terminate the VM immediatelly
Summary: [JUnit] 'Stop JUnit test run' does not terminate the VM immediatelly
Status: ASSIGNED
Alias: None
Product: JDT
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 3.1   Edit
Hardware: PC All
: P3 normal with 9 votes (vote)
Target Milestone: ---   Edit
Assignee: JDT-UI-Inbox CLA
QA Contact:
URL:
Whiteboard: stalebug
Keywords: helpwanted, usability
: 249570 303559 (view as bug list)
Depends on:
Blocks:
 
Reported: 2005-10-13 17:12 EDT by Adam Kiezun CLA
Modified: 2022-05-12 18:49 EDT (History)
10 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Adam Kiezun CLA 2005-10-13 17:12:09 EDT
3.1
I get frustared over this often.
You run your tests, they take a long while each, after a bunch you decide to
stop the execution. 
You press the 'Stop JUnit test run' wanting to halt the execution immediately.
And it doesn't!

Then you must go to the Debug view (why that name? i'm not debugging, i'm
running) and 'Terminate' it from there. That does it.
Comment 1 Adam Kiezun CLA 2005-10-13 17:32:11 EDT
not a *huge* deal, of course. An annoyance nonetheless. :)
Comment 2 Chris CLA 2006-07-14 09:43:01 EDT
Still present in 3.2 (Callisto).
BTW: You don't have to go to Debug view/perspective, the console view can terminate it too.
Comment 3 Dani Megert CLA 2008-10-03 04:24:15 EDT
*** Bug 249570 has been marked as a duplicate of this bug. ***
Comment 4 Philipe Mulet CLA 2008-10-03 07:03:28 EDT
Re: comment 3
Problem in bug 249570 is that the red button is not even enabled early on. I agree though that both issues should be addressed together.
Comment 5 Dani Megert CLA 2008-10-03 09:54:14 EDT
The reason why the Debug/Console terminate is faster is because this kills the
process while the JUnit view stops running the tests and then safely returns
i.e. the the workbench for example isn't killed but correctly exited. Therefore the button is also only enabled once testing has started.
Comment 6 Pascal Rapicault CLA 2010-02-22 19:43:48 EST
*** Bug 303559 has been marked as a duplicate of this bug. ***
Comment 7 Markus Keller CLA 2010-03-03 06:29:05 EST
A fix for this would have to implement this:
- enable the stop button earlier
- when the test run session has already started, try the JUnit way to stop (the existing request for a clean stop that e.g. allows tearDowns of tests and TestSetups to clean up)
- when the stop button is pressed while the test run session has not yet started, or when it is pressed a second time, ask the user whether he wants to terminate the process (default button: Yes)
Comment 8 misja CLA 2011-10-18 03:33:53 EDT
I found a related problem: When I'm debugging a unit test, and, after hitting a breakpoint, I decide to terminate the test in the debug view, the red 'stop' button in the junit pane stays enabled.

I think the current behaviour of the junit stop button is a bit confusing. How about letting it behave like the other stop buttons do, so just let it terminate the proces? Or otherwise maybe add a second button 'kill proces'?
Comment 9 Dmitry Katsubo CLA 2014-01-21 17:56:19 EST
Pity that this bug is still present in 4.3.1 (Kepler).
Comment 10 Alejandro López Vidal CLA 2014-06-04 06:35:51 EDT
And is still present in Luna too.
Comment 11 Eclipse Genie CLA 2020-09-26 16:08:33 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

--
The automated Eclipse Genie.
Comment 12 patins CLA 2022-05-12 18:49:16 EDT
Still present in Eclipse 2022-03
Comment 13 patins CLA 2022-05-12 18:49:48 EDT
Still present in Eclipse 2022-03