ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mohan Radhakrishnan <javat...@yahoo.com>
Subject Process fork failed - Help
Date Mon, 28 Feb 2005 08:14:34 GMT
Hi,

   I read the doc. and the explanation for this error.


1. I removed ant-junit.jar from ANT/lib. What should
my taskdef be in I remove it ? I should point to it
.Right ?

2. JUnit jar is in the classpath.

3. My classes are in the classpath.

   "Process fork failed" is the error I get when I run

  <target name="test" description="Unit test the
application">
  
      <echo>
      	Using C:/UnitTest/lib/ant-junit.jar
      </echo>
     <taskdef name="junit"
classname="org.apache.tools.ant.taskdefs.optional.junit.JUnitTask">
	<classpath>
    	 <pathelement
location="C:/UnitTest/lib/ant-junit.jar" />
	</classpath>
     </taskdef>
  
     <echo>Instrumentation classpath is
${build.instrumented.dir}</echo>
    
    <junit fork="yes" haltonerror="no"
printsummary="withOutAndErr">


      <!--
        note the classpath order, instrumented classes
are before the
        original (uninstrumented) classes.
      -->
      <classpath
location="${build.instrumented.dir}"/>
      <classpath refid="build.classes"/>


      <!--
        the instrumented classes reference classes
used by the
        jcoverage runtime.
      -->
      <classpath refid="jcoverage"/>
      
      <!-- Looks like we don't need these because ANT
adds all the
           JAR'S in ANT/lib to the CLASSPATH. Is this
only for Ant versions
           earlier than ANT 1.6 ?
      <classpath refid="junit"/>-->
      
      <formatter type="brief" usefile="false" />


      <batchtest todir="${build.reports.dir}"
unless="testcase">    	
        <fileset dir="${src.dir}">
          <!--<include
name="**/FranchiseIndicatorServiceTest.java"/>-->
          <!--<include
name="**/DateUtilityTest.java"/>-->
          <include name="**/Test.java"/>
          <!--<include
name="**/PlaceHolderIndicatorServiceTest.java"/>-->
        </fileset>
      </batchtest>
    </junit>
  </target>

If I don't fork then I get this

[junit] Running
com.blockbuster.revenue.allocation.utility.Test
    [junit] Tests run: 1, Failures: 0, Errors: 1, Time
elapsed: 0 sec
    [junit] Testsuite:
com.blockbuster.revenue.allocation.utility.Test
    [junit] Tests run: 1, Failures: 0, Errors: 1, Time
elapsed: 0 sec

    [junit] Null Test:  Caused an ERROR
    [junit]
com.blockbuster.revenue.allocation.utility.Test
    [junit] java.lang.ClassNotFoundException:
com.blockbuster.revenue.allocation
.utility.Test
    [junit]     at
java.net.URLClassLoader$1.run(URLClassLoader.java:195)
    [junit]     at
java.security.AccessController.doPrivileged(Native
Method)
    [junit]     at
java.net.URLClassLoader.findClass(URLClassLoader.java:183)
    [junit]     at
java.lang.ClassLoader.loadClass(ClassLoader.java:294)
    [junit]     at
java.lang.ClassLoader.loadClass(ClassLoader.java:250)
    [junit]     at
java.lang.ClassLoader.loadClass(ClassLoader.java:250)
    [junit]     at
java.lang.ClassLoader.loadClassInternal(ClassLoader.java:310)

    [junit]     at java.lang.Class.forName0(Native
Method)
    [junit]     at
java.lang.Class.forName(Class.java:190)


    [junit] Test
com.blockbuster.revenue.allocation.utility.Test FAILED

Thanks,
Mohan



		
__________________________________ 
Do you Yahoo!? 
Yahoo! Mail - 250MB free storage. Do more. Manage less. 
http://info.mail.yahoo.com/mail_250

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org


Mime
View raw message