mirror of https://github.com/apache/archiva.git
o little conversion of a repository as a smoke test, relying on the good coverage else where :-)
git-svn-id: https://svn.apache.org/repos/asf/maven/repository-manager/trunk@414665 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
e7a794ad0d
commit
565f3f2844
|
@ -65,7 +65,7 @@ public class DefaultRepositoryManager
|
||||||
legacyLayout, null, null );
|
legacyLayout, null, null );
|
||||||
|
|
||||||
repository = artifactRepositoryFactory.createArtifactRepository( "default",
|
repository = artifactRepositoryFactory.createArtifactRepository( "default",
|
||||||
legacyRepositoryDirectory.toURL().toString(),
|
repositoryDirectory.toURL().toString(),
|
||||||
defaultLayout, null, null );
|
defaultLayout, null, null );
|
||||||
}
|
}
|
||||||
catch ( MalformedURLException e )
|
catch ( MalformedURLException e )
|
||||||
|
|
|
@ -2,6 +2,8 @@ package org.apache.maven.repository;
|
||||||
|
|
||||||
import org.codehaus.plexus.PlexusTestCase;
|
import org.codehaus.plexus.PlexusTestCase;
|
||||||
|
|
||||||
|
import java.io.File;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @author Jason van Zyl
|
* @author Jason van Zyl
|
||||||
*/
|
*/
|
||||||
|
@ -11,6 +13,12 @@ public class RepositoryManagerTest
|
||||||
public void testLegacyRepositoryConversion()
|
public void testLegacyRepositoryConversion()
|
||||||
throws Exception
|
throws Exception
|
||||||
{
|
{
|
||||||
|
File legacyRepositoryDirectory = getTestFile( "src/test/maven-1.x-repository" );
|
||||||
|
|
||||||
|
File repositoryDirectory = getTestFile( "target/maven-2.x-repository" );
|
||||||
|
|
||||||
RepositoryManager rm = (RepositoryManager) lookup( RepositoryManager.ROLE );
|
RepositoryManager rm = (RepositoryManager) lookup( RepositoryManager.ROLE );
|
||||||
|
|
||||||
|
rm.convertLegacyRepository( legacyRepositoryDirectory, repositoryDirectory, true );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue