ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From anto...@apache.org
Subject cvs commit: ant/src/etc/testcases/taskdefs checksum.xml
Date Thu, 18 Dec 2003 08:39:06 GMT
antoine     2003/12/18 00:39:06

  Modified:    .        WHATSNEW
               src/main/org/apache/tools/ant/taskdefs Checksum.java
               src/testcases/org/apache/tools/ant/taskdefs
                        ChecksumTest.java
               src/etc/testcases/taskdefs checksum.xml
  Log:
  Make checksum work with nested filesets and no total property
  Make checksum less loud, downgrading message calculating checksum to verbose
  PR: 25606
  PR: 25607
  Submitted by: Ariel Backenroth ( abackenr at interwoven dot com )
  
  Revision  Changes    Path
  1.514     +2 -0      ant/WHATSNEW
  
  Index: WHATSNEW
  ===================================================================
  RCS file: /home/cvs/ant/WHATSNEW,v
  retrieving revision 1.513
  retrieving revision 1.514
  diff -u -r1.513 -r1.514
  --- WHATSNEW	1 Dec 2003 22:10:17 -0000	1.513
  +++ WHATSNEW	18 Dec 2003 08:39:06 -0000	1.514
  @@ -93,6 +93,8 @@
     are resolved at a later stage. This causes some
     differences especially for user defined task containers.
   
  +* <checksum> log message "Calculating checksum ..." has been degraded from INFO to
VERBOSE.
  +
   Fixed bugs:
   -----------
   * Filter readers were not handling line endings properly.  Bugzilla
  
  
  
  1.35      +2 -2      ant/src/main/org/apache/tools/ant/taskdefs/Checksum.java
  
  Index: Checksum.java
  ===================================================================
  RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/Checksum.java,v
  retrieving revision 1.34
  retrieving revision 1.35
  diff -u -r1.34 -r1.35
  --- Checksum.java	13 Sep 2003 12:58:33 -0000	1.34
  +++ Checksum.java	18 Dec 2003 08:39:06 -0000	1.35
  @@ -374,7 +374,7 @@
                   String[] srcFiles = ds.getIncludedFiles();
                   for (int j = 0; j < srcFiles.length; j++) {
                       File src = new File(fs.getDir(getProject()), srcFiles[j]);
  -                    if (totalproperty != null) {
  +                    if (totalproperty != null || todir != null) {
                           // Use '/' to calculate digest based on file name.
                           // This is required in order to get the same result
                           // on different platforms.
  @@ -467,7 +467,7 @@
                   messageDigest.reset();
                   File src = (File) e.nextElement();
                   if (!isCondition) {
  -                    log("Calculating " + algorithm + " checksum for " + src);
  +                    log("Calculating " + algorithm + " checksum for " + src, Project.MSG_VERBOSE);
                   }
                   fis = new FileInputStream(src);
                   DigestInputStream dis = new DigestInputStream(fis,
  
  
  
  1.7       +4 -1      ant/src/testcases/org/apache/tools/ant/taskdefs/ChecksumTest.java
  
  Index: ChecksumTest.java
  ===================================================================
  RCS file: /home/cvs/ant/src/testcases/org/apache/tools/ant/taskdefs/ChecksumTest.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- ChecksumTest.java	24 Jun 2003 15:40:28 -0000	1.6
  +++ ChecksumTest.java	18 Dec 2003 08:39:06 -0000	1.7
  @@ -125,6 +125,9 @@
           expectPropertySet("verifyFromProperty", "verify", "true");
       }
   
  +    public void testVerifyChecksumdirNoTotal() {
  +        executeTarget("verifyChecksumdirNoTotal");
  +    }
       private void testVerify(String target) {
           assertNull(project.getProperty("logo.MD5"));
           assertNull(project.getProperty("no.logo.MD5"));
  
  
  
  1.6       +8 -0      ant/src/etc/testcases/taskdefs/checksum.xml
  
  Index: checksum.xml
  ===================================================================
  RCS file: /home/cvs/ant/src/etc/testcases/taskdefs/checksum.xml,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- checksum.xml	24 Jun 2003 15:40:28 -0000	1.5
  +++ checksum.xml	18 Dec 2003 08:39:06 -0000	1.6
  @@ -65,4 +65,12 @@
         </fileset>
       </checksum>
     </target>
  +    <!-- bug report 25606 -->
  +    <target name="verifyChecksumdirNoTotal">
  +      <checksum todir="${basedir}/checksum/checksums">
  +        <fileset dir="${basedir}/checksum">
  +          <exclude name="**/*.MD5"/>
  +        </fileset>
  +      </checksum>
  +    </target>
   </project>
  
  
  

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


Mime
View raw message