ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Lauzon Daniel-Y18165 <Y18...@motorola.com>
Subject junit crashes on first test of suite
Date Mon, 02 Feb 2004 16:05:05 GMT
This simple bat:

	call ant -f tester.xml
	pause

Mentions this simple xml:

	<project name="tester" default="test">
		<description>
			this will test the app
		</description>
		<target name="test">
			<junit printsummary="true">
				<classpath>
					<pathelement location="src\com\motorola\ptt\tests\unit"/>
					<pathelement location="src\com\motorola\ptt\exception"/>
					<pathelement location="src\com\motorola\ptt\snmp"/>
					<pathelement location="src\com\motorola\ptt"/>
					<pathelement location="src\com\motorola\ptt\tests"/>
					<pathelement location="lib"/>
					<pathelement location="etc"/>
	    			</classpath>
				<formatter type="plain" usefile="false"/>
				<test name="com.motorola.ptt.tests.PostPTTRequest"/>
			</junit>
			<echo message="now leaving test"/>
		</target>
	</project>

I call the bat once the build and deploy is (manually) done and get this error:

	Y:\QUB03ptt-01\src\telus>call ant -f tester.xml
	Buildfile: tester.xml
	
	test:
	    [junit] Running com.motorola.ptt.tests.PostPTTRequest
	    [junit] Tests run: 1, Failures: 0, Errors: 1, Time elapsed: 0 sec
	
	    [junit] Testsuite: com.motorola.ptt.tests.PostPTTRequest	
	    [junit] Tests run: 1, Failures: 0, Errors: 1, Time elapsed: 0 sec
	
	    [junit]     Caused an ERROR
	    [junit] com.motorola.ptt.tests.PostPTTRequest
	    [junit] java.lang.ClassNotFoundException: com.motorola.ptt.tests.PostPTTRequ
	est
	    [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.motorola.ptt.tests.PostPTTRequest FAILED
	     [echo] now leaving test
	
	BUILD SUCCESSFUL
	Total time: 1 second
	Press any key to continue . . .
	
It seems to run the suite and then not find it! 
My extensive classpath includes the road to all the ".jar" and ".java" I could find
I ran in "-diagnosis -d -v" mode but that revealed nothing meaningful

Any input would be greatly appreciated

Dan (aka new2ant)

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


Mime
View raw message