mirror of https://github.com/apache/archiva.git
format : no code change
git-svn-id: https://svn.apache.org/repos/asf/archiva/trunk@1177068 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
3323da7d34
commit
18b92bde16
|
@ -48,9 +48,31 @@ public class BrowseActionTest
|
|||
|
||||
private static final String OTHER_TEST_REPO = "other-repo";
|
||||
|
||||
protected void setUp()
|
||||
throws Exception
|
||||
{
|
||||
super.setUp();
|
||||
setObservableRepos( Lists.<String>newArrayList( "test-repo" ) );
|
||||
action = (BrowseAction) getActionProxy( "/browse.action" ).getAction();
|
||||
metadataResolver = new TestMetadataResolver();
|
||||
RepositorySession repositorySession = mock( RepositorySession.class );
|
||||
when( repositorySession.getResolver() ).thenReturn( metadataResolver );
|
||||
TestRepositorySessionFactory factory =
|
||||
applicationContext.getBean( "repositorySessionFactory#test", TestRepositorySessionFactory.class );
|
||||
factory.setRepositorySession( repositorySession );
|
||||
}
|
||||
|
||||
protected void tearDown()
|
||||
throws Exception
|
||||
{
|
||||
super.tearDown();
|
||||
applicationContext.getBean( DefaultDownloadRemoteIndexScheduler.class ).shutdown();
|
||||
setObservableRepos( Lists.<String>newArrayList( "test-repo" ) );
|
||||
}
|
||||
|
||||
public void testInstantiation()
|
||||
{
|
||||
assertFalse( action == (BrowseAction) getActionProxy( "/browse.action" ).getAction() );
|
||||
assertFalse( action == getActionProxy( "/browse.action" ).getAction() );
|
||||
}
|
||||
|
||||
public void testBrowse()
|
||||
|
@ -389,26 +411,5 @@ public class BrowseActionTest
|
|||
assertNull( action.getSharedModel() );
|
||||
}
|
||||
|
||||
protected void setUp()
|
||||
throws Exception
|
||||
{
|
||||
super.setUp();
|
||||
setObservableRepos( Lists.<String>newArrayList( "test-repo" ) );
|
||||
//action = (BrowseAction) lookup( Action.class, ACTION_HINT );
|
||||
action = (BrowseAction) getActionProxy( "/browse.action" ).getAction();
|
||||
metadataResolver = new TestMetadataResolver();
|
||||
RepositorySession repositorySession = mock( RepositorySession.class );
|
||||
when( repositorySession.getResolver() ).thenReturn( metadataResolver );
|
||||
TestRepositorySessionFactory factory =
|
||||
applicationContext.getBean( "repositorySessionFactory#test", TestRepositorySessionFactory.class );
|
||||
factory.setRepositorySession( repositorySession );
|
||||
}
|
||||
|
||||
protected void tearDown()
|
||||
throws Exception
|
||||
{
|
||||
super.tearDown();
|
||||
applicationContext.getBean( DefaultDownloadRemoteIndexScheduler.class ).shutdown();
|
||||
setObservableRepos( Lists.<String>newArrayList( "test-repo" ) );
|
||||
}
|
||||
}
|
|
@ -91,8 +91,6 @@ public abstract class AbstractRepositoryServletProxiedTestCase
|
|||
|
||||
protected RemoteRepoInfo remoteSnapshots;
|
||||
|
||||
protected RemoteRepoInfo remotePrivateSnapshots;
|
||||
|
||||
@Before
|
||||
public void setUp()
|
||||
throws Exception
|
||||
|
|
|
@ -52,7 +52,6 @@ import java.io.IOException;
|
|||
* @version $Id$
|
||||
*/
|
||||
@RunWith( SpringJUnit4ClassRunner.class )
|
||||
//ContextConfiguration( locations = { "classpath*:/META-INF/spring-context.xml", "classpath*:/spring-context.xml" } )
|
||||
@ContextConfiguration( locations = { "classpath*:/repository-servlet-simple.xml" } )
|
||||
public abstract class AbstractRepositoryServletTestCase
|
||||
extends TestCase
|
||||
|
|
Loading…
Reference in New Issue