mirror of
https://github.com/apache/archiva.git
synced 2025-02-06 18:19:02 +00:00
Updating test cases for ManagedRepositories to not set RoleManager via plexus (to aide in upgrade of redback)
/me runs to the edge of the ring and tags Jesse. git-svn-id: https://svn.apache.org/repos/asf/maven/archiva/trunk@588696 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
2395fea5f0
commit
a7bf8292c3
@ -30,12 +30,12 @@
|
||||
import org.apache.maven.archiva.database.SimpleConstraint;
|
||||
|
||||
/**
|
||||
* DeleteManagedRepositoryArchivaDAOStub
|
||||
* AbstractManagedRepositoryArchivaDAOStub
|
||||
*
|
||||
* @author <a href="mailto:oching@apache.org">Maria Odea Ching</a>
|
||||
* @version
|
||||
*/
|
||||
public class DeleteManagedRepositoryArchivaDAOStub
|
||||
public class AbstractManagedRepositoryArchivaDAOStub
|
||||
implements ArchivaDAO
|
||||
{
|
||||
/**
|
@ -57,7 +57,13 @@ public class AddManagedRepositoryActionTest
|
||||
private static final String REPO_ID = "repo-ident";
|
||||
|
||||
private File location;
|
||||
|
||||
|
||||
@Override
|
||||
protected String getCustomConfigurationName()
|
||||
{
|
||||
return AbstractManagedRepositoriesAction.class.getName().replace( '.', '/' ) + "Test.xml";
|
||||
}
|
||||
|
||||
protected void setUp()
|
||||
throws Exception
|
||||
{
|
||||
|
@ -66,6 +66,12 @@ public class DeleteManagedRepositoryActionTest
|
||||
|
||||
private File location;
|
||||
|
||||
@Override
|
||||
protected String getCustomConfigurationName()
|
||||
{
|
||||
return AbstractManagedRepositoriesAction.class.getName().replace( '.', '/' ) + "Test.xml";
|
||||
}
|
||||
|
||||
protected void setUp()
|
||||
throws Exception
|
||||
{
|
||||
|
@ -57,6 +57,12 @@ public class EditManagedRepositoryActionTest
|
||||
|
||||
private File location;
|
||||
|
||||
@Override
|
||||
protected String getCustomConfigurationName()
|
||||
{
|
||||
return AbstractManagedRepositoriesAction.class.getName().replace( '.', '/' ) + "Test.xml";
|
||||
}
|
||||
|
||||
protected void setUp()
|
||||
throws Exception
|
||||
{
|
||||
|
@ -0,0 +1,98 @@
|
||||
<!--
|
||||
~ Licensed to the Apache Software Foundation (ASF) under one
|
||||
~ or more contributor license agreements. See the NOTICE file
|
||||
~ distributed with this work for additional information
|
||||
~ regarding copyright ownership. The ASF licenses this file
|
||||
~ to you under the Apache License, Version 2.0 (the
|
||||
~ "License"); you may not use this file except in compliance
|
||||
~ with the License. You may obtain a copy of the License at
|
||||
~
|
||||
~ http://www.apache.org/licenses/LICENSE-2.0
|
||||
~
|
||||
~ Unless required by applicable law or agreed to in writing,
|
||||
~ software distributed under the License is distributed on an
|
||||
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
~ KIND, either express or implied. See the License for the
|
||||
~ specific language governing permissions and limitations
|
||||
~ under the License.
|
||||
-->
|
||||
|
||||
<plexus>
|
||||
<components>
|
||||
<component>
|
||||
<role>org.codehaus.plexus.logging.LoggerManager</role>
|
||||
<implementation>org.codehaus.plexus.logging.slf4j.Slf4jLoggerManager</implementation>
|
||||
<lifecycle-handler>basic</lifecycle-handler>
|
||||
</component>
|
||||
|
||||
<component>
|
||||
<role>com.opensymphony.xwork.Action</role>
|
||||
<role-hint>addManagedRepositoryAction</role-hint>
|
||||
<implementation>org.apache.maven.archiva.web.action.admin.repositories.AddManagedRepositoryAction</implementation>
|
||||
<instantiation-strategy>per-lookup</instantiation-strategy>
|
||||
<!-- no requirements set -->
|
||||
</component>
|
||||
|
||||
<component>
|
||||
<role>com.opensymphony.xwork.Action</role>
|
||||
<role-hint>deleteManagedRepositoryAction</role-hint>
|
||||
<implementation>org.apache.maven.archiva.web.action.admin.repositories.DeleteManagedRepositoryAction</implementation>
|
||||
<instantiation-strategy>per-lookup</instantiation-strategy>
|
||||
<requirements>
|
||||
<requirement>
|
||||
<role>org.apache.maven.archiva.database.ArchivaDAO</role>
|
||||
<role-hint>jdo</role-hint>
|
||||
<field-name>archivaDAO</field-name>
|
||||
</requirement>
|
||||
</requirements>
|
||||
</component>
|
||||
|
||||
<component>
|
||||
<role>com.opensymphony.xwork.Action</role>
|
||||
<role-hint>editManagedRepositoryAction</role-hint>
|
||||
<implementation>org.apache.maven.archiva.web.action.admin.repositories.EditManagedRepositoryAction</implementation>
|
||||
<instantiation-strategy>per-lookup</instantiation-strategy>
|
||||
<!-- no requirements set -->
|
||||
</component>
|
||||
|
||||
<!-- DAO : Stubs -->
|
||||
<component>
|
||||
<role>org.apache.maven.archiva.database.ArchivaDAO</role>
|
||||
<role-hint>jdo</role-hint>
|
||||
<implementation>org.apache.maven.archiva.web.action.admin.repositories.AbstractManagedRepositoryArchivaDAOStub</implementation>
|
||||
<requirements>
|
||||
<requirement>
|
||||
<role>org.apache.maven.archiva.database.ArtifactDAO</role>
|
||||
<role-hint>jdo</role-hint>
|
||||
<field-name>artifactDAO</field-name>
|
||||
</requirement>
|
||||
<requirement>
|
||||
<role>org.apache.maven.archiva.database.ProjectModelDAO</role>
|
||||
<role-hint>jdo</role-hint>
|
||||
<field-name>projectModelDAO</field-name>
|
||||
</requirement>
|
||||
<requirement>
|
||||
<role>org.apache.maven.archiva.database.RepositoryContentStatisticsDAO</role>
|
||||
<role-hint>jdo</role-hint>
|
||||
<field-name>repoContentStatisticsDAO</field-name>
|
||||
</requirement>
|
||||
</requirements>
|
||||
</component>
|
||||
<component>
|
||||
<role>org.apache.maven.archiva.database.ArtifactDAO</role>
|
||||
<role-hint>jdo</role-hint>
|
||||
<implementation>org.apache.maven.archiva.web.action.admin.repositories.ArtifactDAOStub</implementation>
|
||||
</component>
|
||||
<component>
|
||||
<role>org.apache.maven.archiva.database.ProjectModelDAO</role>
|
||||
<role-hint>jdo</role-hint>
|
||||
<implementation>org.apache.maven.archiva.web.action.admin.repositories.ProjectModelDAOStub</implementation>
|
||||
</component>
|
||||
<component>
|
||||
<role>org.apache.maven.archiva.database.RepositoryContentStatisticsDAO</role>
|
||||
<role-hint>jdo</role-hint>
|
||||
<implementation>org.apache.maven.archiva.web.action.admin.repositories.RepositoryContentStatisticsDAOStub</implementation>
|
||||
</component>
|
||||
|
||||
</components>
|
||||
</plexus>
|
@ -24,6 +24,11 @@
|
||||
<implementation>org.codehaus.plexus.logging.slf4j.Slf4jLoggerManager</implementation>
|
||||
<lifecycle-handler>basic</lifecycle-handler>
|
||||
</component>
|
||||
<component>
|
||||
<role>org.codehaus.plexus.redback.role.RoleManager</role>
|
||||
<role-hint>default</role-hint>
|
||||
<implementation>org.apache.maven.archiva.web.action.admin.repositories.RoleManagerStub</implementation>
|
||||
</component>
|
||||
<component>
|
||||
<role>com.opensymphony.xwork.Action</role>
|
||||
<role-hint>deleteManagedRepositoryAction</role-hint>
|
||||
|
Loading…
x
Reference in New Issue
Block a user