String proxiedFile = metadataTools.getRepositorySpecificName( proxiedRepoId, requestedResource );
File actualFile = new File( managedDefaultDir, proxiedFile );
assertTrue( actualFile.exists() );
ProjectReference metadata = createProjectReference( requestedResource );
// Build expected metadata XML
StringWriter expectedMetadataXml = new StringWriter();
ArchivaRepositoryMetadata m = new ArchivaRepositoryMetadata();
m.setGroupId( metadata.getGroupId() );
m.setArtifactId( metadata.getArtifactId() );
if ( expectedProxyVersions != null )
{
m.getAvailableVersions().addAll( Arrays.asList( expectedProxyVersions ) );
}