Error with ant build and JUnit task in IntelliJ
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Noah_Cohen
Posted On:   Wednesday, January 18, 2006 11:06 AM

Hi, I seem to be having a very annoying error in IntelliJ. Here are the stats: - IntelliJ 4.5.1, Build 2239 - Using own version of ant (1.5.1) - removed junit37.jar from my ant1.5.1/lib dir, and instead added junit version 3.8.1 of junit.jar to that dir - Specified that same junit.jar in my project classpath (this is the only item in the classpath for my test project) - MyTest.java is the only class in my project, and it is specified as a JUnitTest in run/debug configurations and includes the classpath and jdk of my project module. When I right-click on my test class, and go to "Run" then my simple test passes. I see the results in the run window. Here is where the issue lies (a   More>>
			
Hi,
I seem to be having a very annoying error in IntelliJ. Here are the stats:
- IntelliJ 4.5.1, Build 2239
- Using own version of ant (1.5.1)
- removed junit37.jar from my ant1.5.1/lib dir, and instead added junit version 3.8.1 of junit.jar to that dir
- Specified that same junit.jar in my project classpath (this is the only item in the classpath for my test project)
- MyTest.java is the only class in my project, and it is specified as a JUnitTest in run/debug configurations and includes the classpath and jdk of my project module.

When I right-click on my test class, and go to "Run" then my simple test passes. I see the results in the run window.

Here is where the issue lies (and why this is confusing me). When I try to run *the same test* from my build.xml file in this project, specified with the classpath as the same from my project, and with the following junit task, I get the below error (3 times in a row for whatever reason).

If any of you know of a configuration issue that I may be missing, please let me know. It is very frustrating! Thanks a lot, in advance.
			









Test MyTest failed at org.apache.tools.ant.taskdefs.optional.junit.JUnitTask.execute(JUnitTask.java:568) at org.apache.tools.ant.taskdefs.optional.junit.JUnitTask.execute(JUnitTask.java:527) at org.apache.tools.ant.Task.perform(Task.java:319) at org.apache.tools.ant.Target.execute(Target.java:309) at org.apache.tools.ant.Target.performTasks(Target.java:336)at org.apache.tools.ant.Project.executeTarget(Project.java:1306) at org.apache.tools.ant.Project.executeTargets(Project.java:1250) at org.apache.tools.ant.Main.runBuild(Main.java:610) at org.apache.tools.ant.Main.start(Main.java:196) at org.apache.tools.ant.Main.main(Main.java:235) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:324) at com.intellij.rt.ant.execution.AntMain2.main(AntMain2.java:13)    <<Less

Re: Error with ant build and JUnit task in IntelliJ

Posted By:   Noah_Cohen  
Posted On:   Wednesday, January 18, 2006 01:15 PM

I figured this out - needed the formatter tag to see the output!
About | Sitemap | Contact