You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by el...@apache.org on 2020/03/30 11:09:49 UTC

[maven-dependency-plugin] branch mojo created (now ba52bc9)

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

elharo pushed a change to branch mojo
in repository https://gitbox.apache.org/repos/asf/maven-dependency-plugin.git.


      at ba52bc9  remove debugging code

This branch includes the following new commits:

     new ba52bc9  remove debugging code

The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.



[maven-dependency-plugin] 01/01: remove debugging code

Posted by el...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

elharo pushed a commit to branch mojo
in repository https://gitbox.apache.org/repos/asf/maven-dependency-plugin.git

commit ba52bc907ef2c1a9d3ec50073600b74479277d71
Author: Elliotte Rusty Harold <el...@ibiblio.org>
AuthorDate: Mon Mar 30 07:09:31 2020 -0400

    remove debugging code
---
 .../fromConfiguration/TestUnpackMojo.java           | 21 ---------------------
 1 file changed, 21 deletions(-)

diff --git a/src/test/java/org/apache/maven/plugins/dependency/fromConfiguration/TestUnpackMojo.java b/src/test/java/org/apache/maven/plugins/dependency/fromConfiguration/TestUnpackMojo.java
index eb3ae75..91b0640 100644
--- a/src/test/java/org/apache/maven/plugins/dependency/fromConfiguration/TestUnpackMojo.java
+++ b/src/test/java/org/apache/maven/plugins/dependency/fromConfiguration/TestUnpackMojo.java
@@ -19,7 +19,6 @@ package org.apache.maven.plugins.dependency.fromConfiguration;
  * under the License.    
  */
 
-import org.apache.commons.lang.time.DateFormatUtils;
 import org.apache.maven.artifact.Artifact;
 import org.apache.maven.artifact.versioning.VersionRange;
 import org.apache.maven.execution.MavenSession;
@@ -566,35 +565,15 @@ public class TestUnpackMojo
         File marker = new File( mojo.getMarkersDirectory(), artifact.getId().replace( ':', '-' ) + ".marker" );
         assertTrue( marker.setLastModified( time ) );
 
-        displayFile( "unpackedFile", unpackedFile );
-        displayFile( "artifact    ", artifact.getFile() );
-        displayFile( "marker      ", marker );
-        System.out.println( "mojo.execute()" );
         mojo.execute();
-        displayFile( "unpackedFile", unpackedFile );
-        displayFile( "artifact    ", artifact.getFile() );
-        displayFile( "marker      ", marker );
 
         long markerLastModifiedMillis = Files.getLastModifiedTime( marker.toPath() ).toMillis();
         long unpackedFileLastModifiedMillis = Files.getLastModifiedTime( unpackedFile.toPath() ).toMillis();
 
-        System.out.println( "marker.lastModified() = " + marker.lastModified() );
-        System.out.println( "unpackedFile.lastModified() = " + unpackedFile.lastModified() );
-        System.out.println( "markerLastModifiedMillis = " + markerLastModifiedMillis );
-        System.out.println( "unpackedFileLastModifiedMillis = " + unpackedFileLastModifiedMillis );
-
         assertTrue( "unpackedFile '" + unpackedFile + "' lastModified() == " + markerLastModifiedMillis
                 + ": should be different", markerLastModifiedMillis != unpackedFileLastModifiedMillis );
     }
 
-    private void displayFile( String description, File file ) throws IOException
-    {
-        long toMillis = Files.getLastModifiedTime( file.toPath() ).toMillis();
-        System.out.println( description + ' ' + DateFormatUtils.ISO_DATETIME_FORMAT.format(
-                file.lastModified() ) + ' ' + toMillis + ' ' + file.getPath().substring(
-                getBasedir().length() ) );
-    }
-
     public void assertUnpacked( ArtifactItem item, boolean overWrite )
         throws Exception
     {