You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ant.apache.org by ke...@apache.org on 2007/05/18 10:26:41 UTC

svn commit: r539310 - /ant/core/trunk/src/tests/antunit/taskdefs/retry-test.xml

Author: kevj
Date: Fri May 18 01:26:39 2007
New Revision: 539310

URL: http://svn.apache.org/viewvc?view=rev&rev=539310
Log:
-retry task container

Added:
    ant/core/trunk/src/tests/antunit/taskdefs/retry-test.xml

Added: ant/core/trunk/src/tests/antunit/taskdefs/retry-test.xml
URL: http://svn.apache.org/viewvc/ant/core/trunk/src/tests/antunit/taskdefs/retry-test.xml?view=auto&rev=539310
==============================================================================
--- ant/core/trunk/src/tests/antunit/taskdefs/retry-test.xml (added)
+++ ant/core/trunk/src/tests/antunit/taskdefs/retry-test.xml Fri May 18 01:26:39 2007
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="utf-8"?>
+<project name="retry-test" default="antunit" xmlns:au="antlib:org.apache.ant.antunit">
+  <import file="../antunit-base.xml"/>
+	
+  <target name="test-retry">
+  	<property name="i" value="3"/>
+  	<property name="dest" value="${java.io.tmpdir}/dest"/>
+  	<!-- just in case this ever becomes a legit url... -->
+  	<property name="src" value="http://iojasodjojaosdj"/>
+	<au:expectfailure expectedmessage="Task [get] failed after [${i}] attempts, giving up">
+		<retry retrycount="${i}">
+		  <get src="${src}" dest="${dest}"/>
+		</retry>
+	</au:expectfailure>
+  	<au:assertLogContains text="Attempt [1] error occured, retrying..."/>
+  </target>
+</project>
\ No newline at end of file



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