Skip to main content



      Home
Home » Eclipse Projects » Eclipse Platform » Ant: java.lang.NoClassDefFoundError: org/apache/tools/ant/taskdefs/optional/junit/JUnitTestRunner
Ant: java.lang.NoClassDefFoundError: org/apache/tools/ant/taskdefs/optional/junit/JUnitTestRunner [message #178093] Sat, 10 January 2004 13:30 Go to next message
Eclipse UserFriend
Originally posted by: cwhite.ic.net

After installing M6, I get these error when trying to run ant build scripts
that include the junit task.

[junit] java.lang.NoClassDefFoundError:
org/apache/tools/ant/taskdefs/optional/junit/JUnitTestRunner
[junit] Exception in thread "main

I checked to see the the ANT classpath includes the optional.jar that comes
with the M6 install. It does.

What is the fixed for this?
Re: Ant: java.lang.NoClassDefFoundError: org/apache/tools/ant/taskdefs/optional/junit/JUnitTestRunne [message #178489 is a reply to message #178093] Mon, 12 January 2004 04:58 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: daniel.megert.gmx.net

Chris White wrote:

>After installing M6, I get these error when trying to run ant build scripts
>that include the junit task.
>
>
The following might help:select the JRE page (in the wizard that comes
up when launching your script) and select "Run in the same JRE as the
workspace".

Dani

>[junit] java.lang.NoClassDefFoundError:
> org/apache/tools/ant/taskdefs/optional/junit/JUnitTestRunner
>[junit] Exception in thread "main
>
>I checked to see the the ANT classpath includes the optional.jar that comes
>with the M6 install. It does.
>
>What is the fixed for this?
>
>
>
>
>
>
Re: Ant: java.lang.NoClassDefFoundError: org/apache/tools/ant/taskdefs/optional/junit/JUnitTestRunne [message #183088 is a reply to message #178489] Wed, 21 January 2004 15:49 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: jbennett.liquent.com

Daniel Megert wrote:
> Chris White wrote:
>
>> After installing M6, I get these error when trying to run ant build
>> scripts
>> that include the junit task.
>>
>>
> The following might help:select the JRE page (in the wizard that comes
> up when launching your script) and select "Run in the same JRE as the
> workspace".

Is there any way to avoid this error while using an external JDK? I have
to increase the heap size for my ant script, but I still get the
JUnitTestRunner not found error.

jason
Re: Ant: java.lang.NoClassDefFoundError: org/apache/tools/ant/taskdefs/optional/junit/JUnitTestRunne [message #183125 is a reply to message #183088] Wed, 21 January 2004 16:40 Go to previous messageGo to next message
Eclipse UserFriend
Likely your classpath is not sufficient for the Junit task. If the buildfile
works from the commandline and does not work within Eclipse, please log a
bug report against platform Ant and I will have a look.

Note to increase the heap size when running in the same VM as Eclipse start
eclipse specifying -vmArgs. Something like:
-vmArgs -Xmx450M -Xms250M

HTH
Darins

"Jason Bennett" <jbennett@liquent.com> wrote in message
news:bumohm$pln$1@eclipse.org...
> Daniel Megert wrote:
> > Chris White wrote:
> >
> >> After installing M6, I get these error when trying to run ant build
> >> scripts
> >> that include the junit task.
> >>
> >>
> > The following might help:select the JRE page (in the wizard that comes
> > up when launching your script) and select "Run in the same JRE as the
> > workspace".
>
> Is there any way to avoid this error while using an external JDK? I have
> to increase the heap size for my ant script, but I still get the
> JUnitTestRunner not found error.
>
> jason
>
Re: Ant: java.lang.NoClassDefFoundError: org/apache/tools/ant/taskdefs/optional/junit/JUnitTestRunne [message #183139 is a reply to message #183125] Wed, 21 January 2004 17:30 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: jbennett.liquent.com

Darin Swanson wrote:

> Likely your classpath is not sufficient for the Junit task. If the buildfile
> works from the commandline and does not work within Eclipse, please log a
> bug report against platform Ant and I will have a look.
>
> Note to increase the heap size when running in the same VM as Eclipse start
> eclipse specifying -vmArgs. Something like:
> -vmArgs -Xmx450M -Xms250M

I managed to get the task to work using the internal VM, by specifying
those types of args. Using the external VM, though, never worked.

I suspect that the optional.jar file isn't being handed off properly to
the external VM, but I have no real way to verify that.

jason
Re: Ant: java.lang.NoClassDefFoundError: org/apache/tools/ant/taskdefs/optional/junit/JUnitTestRunne [message #183175 is a reply to message #183139] Wed, 21 January 2004 17:52 Go to previous messageGo to next message
Eclipse UserFriend
Can you please log a bug report

Thanks
Darins

"Jason Bennett" <jbennett@liquent.com> wrote in message
news:bumuem$1v6$1@eclipse.org...
> Darin Swanson wrote:
>
> > Likely your classpath is not sufficient for the Junit task. If the
buildfile
> > works from the commandline and does not work within Eclipse, please log
a
> > bug report against platform Ant and I will have a look.
> >
> > Note to increase the heap size when running in the same VM as Eclipse
start
> > eclipse specifying -vmArgs. Something like:
> > -vmArgs -Xmx450M -Xms250M
>
> I managed to get the task to work using the internal VM, by specifying
> those types of args. Using the external VM, though, never worked.
>
> I suspect that the optional.jar file isn't being handed off properly to
> the external VM, but I have no real way to verify that.
>
> jason
>
Re: Ant: java.lang.NoClassDefFoundError: org/apache/tools/ant/taskdefs/optional/junit/JUnitTestRunne [message #183626 is a reply to message #183175] Thu, 22 January 2004 11:18 Go to previous message
Eclipse UserFriend
Originally posted by: jbennett.liquent.com

Darin Swanson wrote:
> Can you please log a bug report

Done,thanks for your help.

https://bugs.eclipse.org/bugs/show_bug.cgi?id=50400

jason
Previous Topic:editing XML in eclipse (& not lauch browser!)
Next Topic:building javadoc in build process (*.doc.isv plugins)
Goto Forum:
  


Current Time: Thu May 08 15:51:43 EDT 2025

Powered by FUDForum. Page generated in 0.05069 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top