*/
private String path;
+ /**
+ * concat of artifactId+'-'+version+'.'+type
+ * @since 1.4-M3
+ */
+ private String id;
+
public Artifact()
{
this.path = path;
}
+ public String getId()
+ {
+ return id;
+ }
+
+ public void setId( String id )
+ {
+ this.id = id;
+ }
+
@Override
public String toString()
{
sb.append( ", size='" ).append( size ).append( '\'' );
sb.append( ", type='" ).append( type ).append( '\'' );
sb.append( ", path='" ).append( path ).append( '\'' );
+ sb.append( ", id='" ).append( id ).append( '\'' );
sb.append( '}' );
return sb.toString();
}
artifact.setContext( managedRepositoryContent.getId() );
DecimalFormat df = new DecimalFormat( "#,###.##", new DecimalFormatSymbols( Locale.US ) );
artifact.setSize( df.format( s ) + " " + symbol );
+
+ artifact.setId( ref.getArtifactId() + "-" + ref.getVersion() + "." + ref.getType() );
+
return artifact;
}
List<Artifact> list = artifactMap.get( artifact.getVersion() );
Artifact actual = list.get( 0 );
assertEquals( artifact.getNamespace(), actual.getGroupId() );
- assertEquals( artifact.getId(), actual.getArtifactId() );
+ assertEquals( artifact.getId(),actual.getId() );
// olamy test has no more sense as we reuse an other object now
//assertEquals( artifact.getProject(), actual.getGroupId() );
assertEquals( artifact.getRepositoryId(), actual.getRepositoryId() );