delete metadata files for all versions to ensure intergration test works as expected

git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@326389 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Brett Leslie Porter 2005-10-19 04:54:57 +00:00
parent 6fe85e1bd0
commit e6b92f1b17
1 changed files with 49 additions and 51 deletions

View File

@ -222,9 +222,6 @@ public class Verifier
newLine += convertArtifact( artifact ); newLine += convertArtifact( artifact );
newLine += line.substring( index + 1 ); newLine += line.substring( index + 1 );
index = newLine.lastIndexOf( "SNAPSHOT" );
if ( index >= 0 )
{
List l = new ArrayList(); List l = new ArrayList();
l.add( newLine ); l.add( newLine );
@ -246,6 +243,19 @@ public class Verifier
} }
File dir = new File( filespec ); File dir = new File( filespec );
addMetadataToList( dir, hasCommand, l, command );
addMetadataToList( dir.getParentFile(), hasCommand, l, command );
return l;
}
else
{
return Collections.singletonList( line );
}
}
private static void addMetadataToList( File dir, boolean hasCommand, List l, String command )
{
if ( dir.exists() && dir.isDirectory() ) if ( dir.exists() && dir.isDirectory() )
{ {
String[] files = dir.list( new FilenameFilter() String[] files = dir.list( new FilenameFilter()
@ -269,18 +279,6 @@ public class Verifier
} }
} }
} }
return l;
}
else
{
return Collections.singletonList( newLine );
}
}
else
{
return Collections.singletonList( line );
}
} }
private static String convertArtifact( String artifact ) private static String convertArtifact( String artifact )
@ -636,8 +634,8 @@ public class Verifier
cli.createArgument().setLine( "-D" + key + "=" + properties.getProperty( key ) ); cli.createArgument().setLine( "-D" + key + "=" + properties.getProperty( key ) );
} }
boolean useMavenRepoLocal = boolean useMavenRepoLocal = Boolean.valueOf(
Boolean.valueOf( controlProperties.getProperty( "use.mavenRepoLocal", "true" ) ).booleanValue(); controlProperties.getProperty( "use.mavenRepoLocal", "true" ) ).booleanValue();
if ( useMavenRepoLocal ) if ( useMavenRepoLocal )
{ {
// Note: Make sure that the repo is surrounded by quotes as it can possibly have // Note: Make sure that the repo is surrounded by quotes as it can possibly have
@ -852,8 +850,8 @@ public class Verifier
Properties controlProperties = verifier.loadProperties( "verifier.properties" ); Properties controlProperties = verifier.loadProperties( "verifier.properties" );
boolean chokeOnErrorOutput = boolean chokeOnErrorOutput = Boolean.valueOf(
Boolean.valueOf( controlProperties.getProperty( "failOnErrorOutput", "true" ) ).booleanValue(); controlProperties.getProperty( "failOnErrorOutput", "true" ) ).booleanValue();
verifier.executeGoals( properties, controlProperties, "goals.txt" ); verifier.executeGoals( properties, controlProperties, "goals.txt" );