Skip to content

Commit

Permalink
Reduce noise from passing integration tests (#470)
Browse files Browse the repository at this point in the history
  • Loading branch information
elharo authored Nov 17, 2024
1 parent c04f223 commit c6528a9
Show file tree
Hide file tree
Showing 27 changed files with 3 additions and 55 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,21 +22,18 @@ import java.io.*;

File file = new File( basedir, "target/dependency/junit-3.8.1.jar" );

System.out.println( "Checking for existence of " + file );
if ( !file.isFile() )
{
throw new Exception( "Missing " + file );
}

file = new File( basedir, "target/dependency/junit" );
System.out.println( "Checking for existence of " + file );
if ( !file.isDirectory() )
{
throw new Exception( "Missing " + file );
}

file = new File( basedir, "target/repo/junit/junit/3.8.1/junit-3.8.1.jar" );
System.out.println( "Checking for existence of " + file );
if ( !file.isFile() )
{
throw new Exception( "Missing " + file );
Expand Down
1 change: 0 additions & 1 deletion src/it/projects/copy-cli/verify.bsh
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ String[] expectedFiles = {
for ( String expectedFile : expectedFiles )
{
File file = new File( libDir, expectedFile );
System.out.println( "Checking for existence of " + file );
if ( !file.isFile() )
{
throw new Exception( "Missing file " + file );
Expand Down
2 changes: 0 additions & 2 deletions src/it/projects/copy-dependencies/verify.bsh
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ void checkExpected( File dir, String[] expectedFiles )
for ( String expectedFile : expectedFiles )
{
File file = new File( dir, expectedFile );
System.out.println( "Checking for existence of " + file );
if ( !file.isFile() )
{
throw new Exception( "Missing file " + file );
Expand All @@ -39,7 +38,6 @@ void checkExpected( File dir, String[] expectedFiles, String[] unexpectedFiles )
for ( String unexpectedFile : unexpectedFiles )
{
File file = new File( dir, unexpectedFile );
System.out.println( "Checking for inexistence of " + file );
if ( file.isFile() )
{
throw new Exception( "Unexpected file " + file + " found" );
Expand Down
1 change: 0 additions & 1 deletion src/it/projects/copy-from-reactor/verify.bsh
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ String[] expectedFiles = {
for ( String expectedFile : expectedFiles )
{
File file = new File( libDir, expectedFile );
System.out.println( "Checking for existence of " + file );
if ( !file.isFile() )
{
throw new Exception( "Missing file " + file );
Expand Down
1 change: 0 additions & 1 deletion src/it/projects/copy-from-remote-repository/verify.bsh
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ String[] expectedFiles = {
for ( String expectedFile : expectedFiles )
{
File file = new File( localRepositoryPath, expectedFile );
System.out.println( "Checking for existence of " + file );
if ( !file.isFile() )
{
throw new Exception( "Missing file " + file );
Expand Down
1 change: 0 additions & 1 deletion src/it/projects/copy-with-prependGroupId/verify.bsh
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ String[] expectedFiles = {
for ( String expectedFile : expectedFiles )
{
File file = new File( libDir, expectedFile );
System.out.println( "Checking for existence of " + file );
if ( !file.isFile() )
{
throw new Exception( "Missing file " + file );
Expand Down
1 change: 0 additions & 1 deletion src/it/projects/copy/verify.bsh
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ String[] expectedFiles = {
for ( String expectedFile : expectedFiles )
{
File file = new File( libDir, expectedFile );
System.out.println( "Checking for existence of " + file );
if ( !file.isFile() )
{
throw new Exception( "Missing file " + file );
Expand Down
1 change: 0 additions & 1 deletion src/it/projects/get-artifact-maven-plugin/verify.bsh
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ String[] expectedFiles = {
for ( String expectedFile : expectedFiles )
{
File file = new File( localRepositoryPath, expectedFile );
System.out.println( "Checking for existence of " + file );
if ( !file.isFile() )
{
throw new Exception( "Missing file " + file );
Expand Down
2 changes: 0 additions & 2 deletions src/it/projects/get-artifact-no-transitive/verify.bsh
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ String[] expectedFiles = {
for ( String expectedFile : expectedFiles )
{
File file = new File( localRepositoryPath, expectedFile );
System.out.println( "Checking for existence of " + file );
if ( !file.isFile() )
{
throw new Exception( "Missing file " + file );
Expand All @@ -42,7 +41,6 @@ String[] notExpectedFiles = {
for ( String notExpectedFile : notExpectedFiles )
{
File file = new File( localRepositoryPath, notExpectedFile );
System.out.println( "Checking for absence of " + file );
if ( file.isFile() )
{
throw new Exception( "Existing file " + file );
Expand Down
1 change: 0 additions & 1 deletion src/it/projects/get-artifact/verify.bsh
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ String[] expectedFiles = {
for ( String expectedFile : expectedFiles )
{
File file = new File( localRepositoryPath, expectedFile );
System.out.println( "Checking for existence of " + file );
if ( !file.isFile() )
{
throw new Exception( "Missing file " + file );
Expand Down
1 change: 0 additions & 1 deletion src/it/projects/get-gav/verify.bsh
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ String[] expectedFiles = {
for ( String expectedFile : expectedFiles )
{
File file = new File( localRepositoryPath, expectedFile );
System.out.println( "Checking for existence of " + file );
if ( !file.isFile() )
{
throw new Exception( "Missing file " + file );
Expand Down
2 changes: 0 additions & 2 deletions src/it/projects/purge-local-repository-bad-pom/verify.bsh
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,6 @@

import java.io.*;

System.out.println( "Checking for presence of purged dependency directories" );

File depJar = new File( localRepositoryPath, "org/apache/maven/its/dependency/purge-local-repository/1.0/purge-local-repository-1.0.jar" );

if ( !depJar.exists() )
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,6 @@ void createJar( String artifactId )

purgedJar.getParentFile().mkdirs();
purgedJar.createNewFile();

System.out.println( "Created dummy JAR " + purgedJar );
}

createJar( "purged-a" );
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,7 @@ import java.io.File;
void checkFilePurged( String artifactId )
{
File purgedJar = new File( localRepositoryPath, "org/apache/maven/its/dependency/" + artifactId + "/1.0/" + artifactId + "-1.0.jar" );

System.out.println( "Checking for absence of dummy JAR " + purgedJar );


if ( purgedJar.exists() )
{
throw new Exception( "JAR was not purged: " + purgedJar );
Expand Down
2 changes: 0 additions & 2 deletions src/it/projects/purge-local-repository-multi-module/setup.bsh
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,6 @@ void createJar( String artifactId )

purgedJar.getParentFile().mkdirs();
purgedJar.createNewFile();

System.out.println( "Created dummy JAR " + purgedJar );
}

createJar( "purged-a" );
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,6 @@ import java.io.*;

File depDir = new File( localRepositoryPath, "org/apache/maven/its/dependency/purge-local-repository/1.0" );

System.out.println( "Checking for absence of purged dependency directory " + depDir );

if ( depDir.exists() )
{
throw new Exception( "Directory was not deleted: " + depDir );
Expand Down
2 changes: 0 additions & 2 deletions src/it/projects/purge-local-repository-reresolve/verify.bsh
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,6 @@

import java.io.*;

System.out.println( "Checking for presence of purged dependency directories" );

File depJar = new File( localRepositoryPath, "org/apache/maven/its/dependency/purge-local-repository/1.0/purge-local-repository-1.0.jar" );

if ( !depJar.exists() )
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,14 +24,9 @@ File purgedJar = new File( localRepositoryPath, "org/apache/maven/its/dependency
purgedJar.getParentFile().mkdirs();
purgedJar.createNewFile();

System.out.println( "Created dummy JAR " + purgedJar );

purgedJar = new File( localRepositoryPath, "org/apache/maven/its/dependency/snap-purged/1.0-SNAPSHOT/snap-purged-1.0-SNAPSHOT.jar" );

purgedJar.getParentFile().mkdirs();
purgedJar.createNewFile();

System.out.println( "Created dummy JAR " + purgedJar );


return true;
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,6 @@ import java.io.*;

File nonPurgedJar = new File( localRepositoryPath, "org/apache/maven/its/dependency/purged/1.0/purged-1.0.jar" );

System.out.println( "Checking for presence of dummy JAR " + nonPurgedJar );

if ( !nonPurgedJar.exists() )
{
throw new Exception( "JAR was purged: " + nonPurgedJar );
Expand All @@ -31,8 +29,6 @@ if ( !nonPurgedJar.exists() )

File purgedJar = new File( localRepositoryPath, "org/apache/maven/its/dependency/snap-purged/1.0-SNAPSHOT/snap-purged-1.0-SNAPSHOT.jar" );

System.out.println( "Checking for absence of dummy JAR " + purgedJar );

if ( purgedJar.exists() )
{
throw new Exception( "JAR was not purged: " + purgedJar );
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,6 @@

import java.io.*;

System.out.println( "Checking for presence of purged dependency directories" );

File depJar = new File( localRepositoryPath, "org/apache/maven/its/dependency/purge-local-repository/1.0/purge-local-repository-1.0.jar" );

if ( !depJar.exists() )
Expand Down
2 changes: 0 additions & 2 deletions src/it/projects/purge-local-repository-without-pom/setup.bsh
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,4 @@ File purgedJar = new File( localRepositoryPath, "org/apache/maven/its/dependency
purgedJar.getParentFile().mkdirs();
purgedJar.createNewFile();

System.out.println( "Created dummy JAR " + purgedJar );

return true;
2 changes: 0 additions & 2 deletions src/it/projects/purge-local-repository/setup.bsh
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,4 @@ File purgedJar = new File( localRepositoryPath, "org/apache/maven/its/dependency
purgedJar.getParentFile().mkdirs();
purgedJar.createNewFile();

System.out.println( "Created dummy JAR " + purgedJar );

return true;
1 change: 0 additions & 1 deletion src/it/projects/purge-local-repository/verify.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@
void checkFileAbsence( String path )
{
File depJar = new File( localRepositoryPath, path )
System.out.println( "Checking for absence of dummy JAR " + depJar )
if ( depJar.exists() )
{
throw new Exception( "Dependency jar was not purged: " + depJar )
Expand Down
4 changes: 0 additions & 4 deletions src/it/projects/unpack-cli/verify.bsh
Original file line number Diff line number Diff line change
Expand Up @@ -21,29 +21,25 @@ import java.io.*;


File file = new File( basedir, "target/output spaces directory" );
System.out.println( "Checking for existence of " + file );
if ( !file.isDirectory() )
{
throw new Exception( "Missing " + file );
}

file = new File( file, "qdox-1.5" );
System.out.println( "Checking for existence of " + file );
if ( !file.isDirectory() )
{
throw new Exception( "Missing " + file );
}

file = new File( file, "build.xml" );
System.out.println( "Checking for existence of " + file );
if ( !file.isFile() )
{
throw new Exception( "Missing " + file );
}

//until MDEP-242 is fixed, the next test will passed
file = new File( file.getParent(), "src" );
System.out.println( "Checking for existence of " + file );
if ( !file.isDirectory() )
{
throw new Exception( "Missing " + file );
Expand Down
4 changes: 2 additions & 2 deletions src/it/projects/unpack-dependencies/verify.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ for (item in expected)
def file = new File(basedir, 'target/dependency/' + item)
if (!file.exists())
{
throw new RuntimeException("Missing "+file.name)
throw new RuntimeException("Missing " + file.name)
}
}

Expand All @@ -35,7 +35,7 @@ for (item in notExpected)
def file = new File(basedir, 'target/dependency/' + item)
if (file.exists())
{
throw new RuntimeException("This file shouldn't be here: "+file.name)
throw new RuntimeException("This file shouldn't be here: " + file.name)
}
}

Expand Down
1 change: 0 additions & 1 deletion src/it/projects/unpack-from-remote-repository/verify.bsh
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ String[] expectedFiles = {
for ( String expectedFile : expectedFiles )
{
File file = new File( localRepositoryPath, expectedFile );
System.out.println( "Checking for existence of " + file );
if ( !file.isFile() )
{
throw new Exception( "Missing file " + file );
Expand Down
4 changes: 0 additions & 4 deletions src/it/projects/unpack/verify.bsh
Original file line number Diff line number Diff line change
Expand Up @@ -21,29 +21,25 @@ import java.io.*;


File file = new File( basedir, "target/output spaces directory" );
System.out.println( "Checking for existence of " + file );
if ( !file.isDirectory() )
{
throw new Exception( "Missing " + file );
}

file = new File( file, "qdox-1.5" );
System.out.println( "Checking for existence of " + file );
if ( !file.isDirectory() )
{
throw new Exception( "Missing " + file );
}

file = new File( file, "build.xml" );
System.out.println( "Checking for existence of " + file );
if ( !file.isFile() )
{
throw new Exception( "Missing " + file );
}

//until MDEP-242 is fixed, the next test will passed
file = new File( file.getParent(), "src" );
System.out.println( "Checking for existence of " + file );
if ( !file.isDirectory() )
{
throw new Exception( "Missing " + file );
Expand Down

0 comments on commit c6528a9

Please sign in to comment.