Skip to content

Commit

Permalink
[NEXUS-4923] Better message in case of failing
Browse files Browse the repository at this point in the history
Signed-off-by: Alin Dreghiciu <adreghiciu@gmail.com>
  • Loading branch information
adreghiciu committed Apr 9, 2012
1 parent ac1338d commit a40ae88
Showing 1 changed file with 7 additions and 2 deletions.
Expand Up @@ -16,9 +16,11 @@
import java.io.FileInputStream;
import java.io.FileOutputStream;
import java.io.IOException;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Calendar;
import java.util.Date;
import java.util.List;

import org.apache.commons.io.FileUtils;
import org.sonatype.nexus.integrationtests.AbstractNexusIntegrationTest;
Expand Down Expand Up @@ -95,12 +97,15 @@ public void clearProxy()

boolean isAllDotFiles = true;

List<String> paths = new ArrayList<String>();

for ( File file : files )
{
paths.add( file.getPath() );
isAllDotFiles = isAllDotFiles && file.getName().startsWith( "." );
}

Assert.assertTrue( isAllDotFiles, "The only files left should be \"dotted\" files! We have: " + files );
Assert.assertTrue( isAllDotFiles, "The only files left should be \"dotted\" files! We have: " + paths );
}
}

Expand All @@ -111,7 +116,7 @@ public void keepTestDeployedFiles()
executeTask( "keepTestDeployedFiles", "release-proxy-repo-1", 2 );

File artifact = new File( repositoryPath, "nexus636/artifact-new/1.0/artifact-new-1.0.jar" );
Assert.assertTrue( artifact.exists(), "The files deployed by this test should be young enought to be kept" );
Assert.assertTrue( artifact.exists(), "The files deployed by this test should be young enough to be kept" );

}

Expand Down

0 comments on commit a40ae88

Please sign in to comment.