Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Path setting problem in java task

 
J J Singh
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi i am using the following code



and my javac target is



I get the message that path variable org.compile.classpath is not set when i try to run this. Can you please point out what is the mistake.
 
Vijitha Kumara
Bartender
Posts: 3913
9
Chrome Fedora Hibernate
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Welcome to CodeRanch

There are many ways to do this, one way would be to refer the path to jar files in classpath of the javac task.

Then use this as a refid to the classpath
 
J J Singh
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thank You , classpath is working now.

I have following problem further.

I am using Ant 1.8.2 and Junit 4.8

My build file is



When i run this from Eclipse it runs fine.

When i try to run it using Ant outside eclipse it gives error as Failed

The targets are clean , init ,compile.org , compile.test , testing.junit

When i run clean , init , compile.org and comiple.test from ant it runs fine. But when i run the testing.junit inside ant it gives error as




My code for Calculator.java and its test class CalculatorTest.java is




CalculatorTest.java





Thanks once again in advance
 
Mark Kin
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Did you figure this out ? I have the same issue.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic