How to get JUnit to timeout within ant?
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Paul_Crowley
Posted On:   Monday, June 24, 2002 12:04 PM

I am trying to automate testing, within my ant build script. One of my tests should fail due to timeout, but it is not working properly. My build.xml looks like this: location='/tools/lib/xerces.jar' /> location='/tools/lib/junit.jar' /> If the test takes more than 2000ms I want it to quit, instead it appears as though it runs the test to completion.. and then checks to see if it finished within the timeframe, and then throws the error. How can I make ant stop the test once the time limit is reached? I am using Ant version 1.4.1 compiled on October 11 2001.    More>>

I am trying to automate testing, within my ant build script. One of my tests should fail due to timeout, but it is not working properly. My build.xml looks like this:









location='/tools/lib/xerces.jar' />


location='/tools/lib/junit.jar' />



















If the test takes more than 2000ms I want it to quit, instead it appears as though it runs the test to completion.. and then checks to see if it finished within the timeframe, and then throws the error. How can I make ant stop the test once the time limit is reached?


I am using Ant version 1.4.1 compiled on October 11 2001.

   <<Less

Re: How to get JUnit to timeout within ant?

Posted By:   Paul_Crowley  
Posted On:   Thursday, July 18, 2002 12:35 PM

I found out my problem. I was using a old jdk. With jdk 1.3.1 it works properly.
About | Sitemap | Contact