This is an automated email from the ASF dual-hosted git repository.

asf-gitbox-commits pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/ant-antlibs-common.git


The following commit(s) were added to refs/heads/master by this push:
     new 2dce9ab  use Ivy dependencies during AntUnit tests as well
2dce9ab is described below

commit 2dce9ab4f1fa73d0cbd44c7784fe245f7505f779
Author: Stefan Bodewig <[email protected]>
AuthorDate: Sun Apr 26 16:59:05 2026 +0200

    use Ivy dependencies during AntUnit tests as well
---
 build.xml | 19 ++++++++++++++++---
 1 file changed, 16 insertions(+), 3 deletions(-)

diff --git a/build.xml b/build.xml
index 4463778..5a17755 100644
--- a/build.xml
+++ b/build.xml
@@ -113,13 +113,15 @@
 
   <target name="setup-for-junit-tests" depends="setup,determine-test-types"
     unless="skip-junit">
-    <available classname="junit.framework.TestCase" 
property="junit-present?"/>    
+    <available classname="junit.framework.TestCase"
+      property="junit-present?"
+      classpathref="classpath.test"/>
     <fail unless="junit-present?">The JUnit library is not present.</fail>
             
     <available classname="org.apache.tools.ant.BuildFileTest"
       property="testutil-present?"
       ignoresystemclasses="true"
-      classpath="${ant-testutil.jar}"/>
+      classpathref="classpath.test"/>
 
     <fail unless="testutil-present?">Expected to find ant-testutil.jar
     in ${ant-testutil.jar}, please set the property ant-testutil.jar
@@ -129,7 +131,8 @@
   <target name="setup-for-antunit-tests" depends="setup,determine-test-types"
     unless="skip-antunit">
     <available classname="org.apache.ant.antunit.AntUnit"
-      property="antunit-present?"/>
+      property="antunit-present?"
+      classpathref="classpath.test"/>
 
     <fail unless="antunit-present?">The AntUnit Ant library is not 
present.</fail>
   </target>
@@ -192,6 +195,10 @@
     <property name="antunit.excludes" value="" />
 
     <mkdir dir="${antunit.report.dir}" />
+    <typedef uri="antlib:org.apache.ant.antunit"
+      resource="org/apache/ant/antunit/antlib.xml"
+      classpathref="classpath.test"/>
+    <property name="antlib.location" location="${jarname}"/>
     <au:antunit xmlns:au="antlib:org.apache.ant.antunit"
       failOnError="false"
       errorProperty="antunit.tests.failed"
@@ -201,6 +208,12 @@
 
       <au:xmllistener todir="${antunit.report.dir}" />
       <au:plainlistener/>
+      <referenceset>
+        <reference refid="classpath.test"/>
+      </referenceset>
+      <propertyset>
+        <propertyref name="antlib.location"/>
+      </propertyset>
     </au:antunit>
   </target>
 

Reply via email to