From 3e959d5b07d1cbd0f6111b59d8928e9502aa258f Mon Sep 17 00:00:00 2001 From: Martin Stockhammer Date: Mon, 9 Aug 2021 23:40:20 +0200 Subject: Refactoring repository registry --- .../test/java/org/apache/archiva/proxy/AbstractProxyTestCase.java | 6 ++++++ .../java/org/apache/archiva/proxy/CacheFailuresTransferTest.java | 2 ++ .../test/java/org/apache/archiva/proxy/HttpProxyTransferTest.java | 6 ++++++ 3 files changed, 14 insertions(+) (limited to 'archiva-modules/archiva-maven/archiva-maven-proxy/src') diff --git a/archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/proxy/AbstractProxyTestCase.java b/archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/proxy/AbstractProxyTestCase.java index ec1a5319d..18bc3a3ab 100644 --- a/archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/proxy/AbstractProxyTestCase.java +++ b/archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/proxy/AbstractProxyTestCase.java @@ -25,6 +25,7 @@ import org.apache.archiva.policies.*; import org.apache.archiva.proxy.model.RepositoryProxyHandler; import org.apache.archiva.repository.*; import org.apache.archiva.repository.base.managed.BasicManagedRepository; +import org.apache.archiva.repository.base.managed.ManagedRepositoryHandler; import org.apache.archiva.repository.storage.StorageAsset; import org.apache.archiva.test.utils.ArchivaSpringJUnit4ClassRunner; import org.apache.maven.wagon.Wagon; @@ -70,6 +71,11 @@ public abstract class AbstractProxyTestCase @Inject RepositoryRegistry repositoryRegistry; + @SuppressWarnings( "unused" ) + @Inject + ManagedRepositoryHandler managedRepositoryHandler; + + protected static final String ID_PROXIED1 = "proxied1"; protected static final String ID_PROXIED1_TARGET = "proxied1-target"; diff --git a/archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/proxy/CacheFailuresTransferTest.java b/archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/proxy/CacheFailuresTransferTest.java index 83728f189..94a04f194 100644 --- a/archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/proxy/CacheFailuresTransferTest.java +++ b/archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/proxy/CacheFailuresTransferTest.java @@ -25,6 +25,7 @@ import org.apache.archiva.policies.ChecksumPolicy; import org.apache.archiva.policies.ReleasesPolicy; import org.apache.archiva.policies.SnapshotsPolicy; import org.apache.archiva.policies.urlcache.UrlFailureCache; +import org.apache.archiva.repository.base.managed.ManagedRepositoryHandler; import org.apache.archiva.repository.content.BaseRepositoryContentLayout; import org.apache.archiva.repository.content.Artifact; import org.apache.archiva.repository.storage.StorageAsset; @@ -53,6 +54,7 @@ public class CacheFailuresTransferTest @Inject UrlFailureCache urlFailureCache; + @Test public void testGetWithCacheFailuresOn( ) throws Exception diff --git a/archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/proxy/HttpProxyTransferTest.java b/archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/proxy/HttpProxyTransferTest.java index a2ab1a299..f7a4cbf40 100644 --- a/archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/proxy/HttpProxyTransferTest.java +++ b/archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/proxy/HttpProxyTransferTest.java @@ -30,6 +30,7 @@ import org.apache.archiva.policies.PropagateErrorsOnUpdateDownloadPolicy; import org.apache.archiva.policies.ReleasesPolicy; import org.apache.archiva.policies.SnapshotsPolicy; import org.apache.archiva.proxy.model.RepositoryProxyHandler; +import org.apache.archiva.repository.base.managed.ManagedRepositoryHandler; import org.apache.archiva.repository.content.BaseRepositoryContentLayout; import org.apache.archiva.repository.ManagedRepository; import org.apache.archiva.repository.ManagedRepositoryContent; @@ -100,6 +101,11 @@ public class HttpProxyTransferTest @Inject private ProxyRegistry proxyRegistry; + @SuppressWarnings( "unused" ) + @Inject + ManagedRepositoryHandler managedRepositoryHandler; + + private Server server; protected ManagedRepositoryContent createRepository( String id, String name, String path, String layout ) -- cgit v1.2.3