diff --git a/tycho-surefire/tycho-surefire-plugin/src/main/java/org/eclipse/tycho/surefire/AbstractEclipseTestMojo.java b/tycho-surefire/tycho-surefire-plugin/src/main/java/org/eclipse/tycho/surefire/AbstractEclipseTestMojo.java
index 654b82e903..bb6e8a32f0 100644
--- a/tycho-surefire/tycho-surefire-plugin/src/main/java/org/eclipse/tycho/surefire/AbstractEclipseTestMojo.java
+++ b/tycho-surefire/tycho-surefire-plugin/src/main/java/org/eclipse/tycho/surefire/AbstractEclipseTestMojo.java
@@ -40,24 +40,24 @@
import java.util.StringJoiner;
import java.util.concurrent.ExecutionException;
+import org.apache.maven.RepositoryUtils;
import org.apache.maven.artifact.Artifact;
-import org.apache.maven.artifact.resolver.ArtifactResolutionException;
-import org.apache.maven.artifact.resolver.ArtifactResolutionRequest;
-import org.apache.maven.artifact.resolver.ArtifactResolutionResult;
-import org.apache.maven.artifact.resolver.ResolutionErrorHandler;
import org.apache.maven.model.Dependency;
import org.apache.maven.model.Repository;
import org.apache.maven.plugin.MojoExecutionException;
import org.apache.maven.plugin.MojoFailureException;
import org.apache.maven.plugins.annotations.Component;
import org.apache.maven.plugins.annotations.Parameter;
-import org.apache.maven.repository.RepositorySystem;
import org.apache.maven.surefire.api.booter.ProviderParameterNames;
import org.apache.maven.surefire.api.util.ScanResult;
import org.apache.maven.surefire.booter.BooterConstants;
import org.apache.maven.surefire.booter.PropertiesWrapper;
import org.codehaus.plexus.util.FileUtils;
import org.codehaus.plexus.util.cli.CommandLineUtils;
+import org.eclipse.aether.RepositorySystem;
+import org.eclipse.aether.resolution.ArtifactRequest;
+import org.eclipse.aether.resolution.ArtifactResolutionException;
+import org.eclipse.aether.resolution.ArtifactResult;
import org.eclipse.equinox.internal.p2.metadata.IRequiredCapability;
import org.eclipse.equinox.p2.metadata.IRequirement;
import org.eclipse.equinox.spi.p2.publisher.PublisherHelper;
@@ -325,9 +325,6 @@ public abstract class AbstractEclipseTestMojo extends AbstractTestMojo {
@Component
protected RepositorySystem repositorySystem;
- @Component
- private ResolutionErrorHandler resolutionErrorHandler;
-
@Component(role = TychoProject.class)
private Maporg.apache.felix.scr
to make declarative services
- * work), they need to be added manually through an extraRequirements
configuration on the
- * target-platform-configuration
plugin.
+ * work), they need to be added manually through an extraRequirements
configuration on
+ * the target-platform-configuration
plugin.
*
* This goal adopts the maven-failsafe paradigm, that works in the following way:
@@ -99,6 +100,9 @@ public class TychoIntegrationTestMojo extends AbstractEclipseTestMojo {
@Parameter(defaultValue = "${localRepository}", required = true, readonly = true)
private ArtifactRepository localRepository;
+ @Component
+ protected org.apache.maven.repository.RepositorySystem oldRepositorySystem;
+
/**
* Configures the packaging type where this mojos applies
*/
@@ -201,7 +205,7 @@ protected boolean useMetadataDirectory(ReactorProject otherProject) {
}
private ArtifactResolutionResult resolveDependency(final Dependency dependency) {
- final var artifact = repositorySystem.createDependencyArtifact(dependency);
+ final var artifact = oldRepositorySystem.createDependencyArtifact(dependency);
final var remoteRepositories = new ArrayList