NOTE: this thread was migrated from projectzero.org. Some content and formatting may have been lost in the move.
Originally posted by projectzero userid: dcosenti - f=4&t=2320#p9409
I have developed a test class for some smash code of mine.
Seems like my tests are run twice when I run the "zero test" command, any idea why?
I am using junit 4.3.1 and my test class is structured like this:
public static void setup() throws IOException
public static void tearDown() throws MalformedURLException
Thanks for any hint.
NOTICE: developerWorks Community will be offline May 29-30, 2015 while we upgrade to the latest version of IBM Connections. For more information, read our upgrade FAQ.
This topic has been locked.
3 replies Latest Post - 2011-07-04T05:19:27Z by SystemAdmin
Pinned topic junit tests are run twice. why?
Answered question This question has been answered.
Unanswered question This question has not been answered yet.
Updated on 2011-07-04T05:19:27Z at 2011-07-04T05:19:27Z by SystemAdmin
Re: junit tests are run twice. why?2011-06-09T09:12:55Z in response to SystemAdmin
Originally posted by projectzero userid: KentaTakahashi - f=4&t=2320#p9410
Are you using eclipse and Groovy-Eclipse plugin, and writing test code by groovy?
"zero test" finds 2 test classes in "/app/scripts" and "/classes", so tests are run twice.
Groovy-Eclipse plugins are compiling groovy files to "/classes" folder.
But it is not recommended in unit test because Groovy-Eclipse plugin's groovy is often different from zero.core's groovy.
I always turn off Groovy-Eclipse's build in test phase.
Re: junit tests are run twice. why?2011-07-04T05:19:27Z in response to SystemAdmin
Originally posted by projectzero userid: KentaTakahashi - f=4&t=2320#p9421
I find I can configure settings to each build paths of class folders in a eclipse.
I don't have to turn off Groovy-Eclipse, just only I configure settings below.
- check "Allow output folders for source folder" in Java Build Path
- configure a build path of "/app/scripts" to a other folder like "/groovy_classes".)