ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From co...@apache.org
Subject cvs commit: jakarta-ant/src/testcases/org/apache/tools/ant/taskdefs/optional/depend DependTest.java
Date Tue, 09 Apr 2002 03:51:19 GMT
conor       02/04/08 20:51:19

  Modified:    src/etc/testcases/taskdefs/optional/depend depend.xml
               src/testcases/org/apache/tools/ant/taskdefs/optional/depend
                        DependTest.java
  Log:
  Test depend cache
  
  Revision  Changes    Path
  1.7       +8 -0      jakarta-ant/src/etc/testcases/taskdefs/optional/depend/depend.xml
  
  Index: depend.xml
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/etc/testcases/taskdefs/optional/depend/depend.xml,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -w -u -r1.6 -r1.7
  --- depend.xml	9 Apr 2002 02:37:54 -0000	1.6
  +++ depend.xml	9 Apr 2002 03:51:19 -0000	1.7
  @@ -7,6 +7,7 @@
     <property name="src4.dir" value="src4"/>
     
     <property name="tempsrc.dir" value="working"/>
  +  <property name="cache.dir" value="working"/>
     <property name="classes.dir" value="classes"/>
     <target name="help">
       <echo>This buildfile is used as part of Ant's test suite.</echo>
  @@ -128,5 +129,12 @@
               classpathref="path.compile"/>
              
       <fileset id="result" dir="${classes.dir}"/>
  +  </target>
  +  
  +  <target name="testcache" depends="src1setup, compile">
  +    <depend cache="${cache.dir}" srcdir="${tempsrc.dir}" 
  +            destdir="${classes.dir}" closure="yes"/>
  +    <depend cache="${cache.dir}" srcdir="${tempsrc.dir}" 
  +            destdir="${classes.dir}" closure="yes"/>
     </target>
   </project>
  
  
  
  1.4       +14 -0     jakarta-ant/src/testcases/org/apache/tools/ant/taskdefs/optional/depend/DependTest.java
  
  Index: DependTest.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/testcases/org/apache/tools/ant/taskdefs/optional/depend/DependTest.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -w -u -r1.3 -r1.4
  --- DependTest.java	9 Apr 2002 02:37:54 -0000	1.3
  +++ DependTest.java	9 Apr 2002 03:51:19 -0000	1.4
  @@ -151,6 +151,12 @@
               "No source specified", "srcdir attribute must be non-empty");
       }
   
  +    /**
  +     * Read the result fileset into a Hashtable
  +     * 
  +     * @return a Hashtable containing the names of the files in the result 
  +     * fileset
  +     */
       private Hashtable getResultFiles() {
           FileSet resultFileSet = (FileSet)project.getReference(RESULT_FILESET);
           DirectoryScanner scanner = resultFileSet.getDirectoryScanner(project);
  @@ -173,4 +179,12 @@
           assertEquals("Depend did not leave correct number of files", 2, 
               getResultFiles().size());
       }
  +
  +    /**
  +     * Test the operation of the cache
  +     */
  +    public void testCache() {
  +        executeTarget("testcache");
  +    }
  +
   }
  
  
  

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


Mime
View raw message