mirror of https://github.com/apache/archiva.git
fix tests after struts upgrade
Context no longer automatically populated git-svn-id: https://svn.apache.org/repos/asf/archiva/branches/archiva-1.3.x@1563564 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
f216ee5a9f
commit
6103fa368f
|
@ -19,8 +19,10 @@ package org.apache.maven.archiva.web.action;
|
|||
* under the License.
|
||||
*/
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
|
||||
import com.opensymphony.xwork2.ActionContext;
|
||||
import org.apache.maven.archiva.model.ArchivaProjectModel;
|
||||
import org.apache.maven.archiva.security.UserRepositories;
|
||||
import org.apache.maven.archiva.security.UserRepositoriesStub;
|
||||
|
@ -75,6 +77,15 @@ public abstract class AbstractActionTestCase
|
|||
|
||||
protected static final String TEST_SCM_URL = "scmUrl";
|
||||
|
||||
@Override
|
||||
protected void setUp()
|
||||
throws Exception
|
||||
{
|
||||
super.setUp();
|
||||
|
||||
ActionContext.setContext( new ActionContext( new HashMap<String, Object>() ) );
|
||||
}
|
||||
|
||||
protected void setObservableRepos( List<String> repoIds )
|
||||
{
|
||||
UserRepositoriesStub repos = (UserRepositoriesStub) lookup( UserRepositories.class );
|
||||
|
|
Loading…
Reference in New Issue