use of org.apache.maven.artifact.repository.layout.LegacyRepositoryLayout in project felix by apache.
the class AbstractBundlePluginTest method getMavenProjectStub.
protected MavenProjectStub getMavenProjectStub() {
MavenProjectStub project = new MavenProjectStub();
project.setGroupId("group");
project.setArtifactId("project");
project.setVersion("1.2.3.4");
VersionRange versionRange = VersionRange.createFromVersion(project.getVersion());
ArtifactHandler artifactHandler = new DefaultArtifactHandler("pom");
Artifact artifact = new DefaultArtifact(project.getGroupId(), project.getArtifactId(), versionRange, null, "pom", null, artifactHandler);
artifact.setResolved(true);
project.setArtifact(artifact);
ProjectBuilderConfiguration projectBuilderConfiguration = new DefaultProjectBuilderConfiguration();
ArtifactRepositoryLayout layout = new LegacyRepositoryLayout();
ArtifactRepository artifactRepository = new DefaultArtifactRepository("scratch", new File(getBasedir(), "target" + File.separatorChar + "scratch").toURI().toString(), layout);
projectBuilderConfiguration.setLocalRepository(artifactRepository);
project.setProjectBuilderConfiguration(projectBuilderConfiguration);
return project;
}
Aggregations