| Author |
Skip or order JUnit tests in Eclipse
|
Min Huang
Greenhorn
Joined: Sep 21, 2004
Posts: 16
|
|
Is there a way to do this? I understand that having this need reveals a deeper problem in my unit tests themselves (ie they are not actually unit tests, but functional or they are just plain bad, bad I tell you!), but please humor me
|
SCJP, SCJD, SCBCD, SCWCD
|
 |
Jan Cumps
Bartender
Joined: Dec 20, 2006
Posts: 2343
|
|
You can skip tests by annotating them with @Ignore. You can't order tests (if order means: decide in which order they run; JUnit does not guarantee a specific order of execution), but you can group tests as described in Lasse's weblog. Regards, jan
|
OCUP UML fundamental
ITIL foundation
|
 |
Min Huang
Greenhorn
Joined: Sep 21, 2004
Posts: 16
|
|
|
Sorry, I didn't specify that this is JUnit3 specific. I strongly suspect that there is nothing I can do in this situation..
|
 |
Jeanne Boyarsky
internet detective
Marshal
Joined: May 26, 2003
Posts: 26184
|
|
You can also implement your own suite method and hard code the order of the tests. Then have Eclipse run that. Keep in mind that you have to maintain the suite then which is problematic.
|
[Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Blogging on Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, OCAJP, OCPJP beta, TOGAF part 1 and part 2
|
 |
Min Huang
Greenhorn
Joined: Sep 21, 2004
Posts: 16
|
|
|
Yes, I realize that. I was just wondering if there is some easy way to do it. I did stumble upon ct-eclipse, but there is are no files available for downloading. I was hoping if somebody knew of an alternative.
|
 |
 |
|
|
subject: Skip or order JUnit tests in Eclipse
|
|
|