]> source.dussan.org Git - archiva.git/commitdiff
fix junit GenerateReportActionTest
authorOlivier Lamy <olamy@apache.org>
Tue, 14 Jun 2011 16:51:45 +0000 (16:51 +0000)
committerOlivier Lamy <olamy@apache.org>
Tue, 14 Jun 2011 16:51:45 +0000 (16:51 +0000)
git-svn-id: https://svn.apache.org/repos/asf/archiva/trunk@1135696 13f79535-47bb-0310-9956-ffa450edef68

archiva-modules/archiva-web/archiva-webapp/src/test/java/org/apache/maven/archiva/web/action/reports/GenerateReportActionTest.java

index c1144c2a98778e53b6f67064eda4ecad952a145d..6bc27bd8f87e5b3ea4304bc0db01a49449d47fc3 100644 (file)
@@ -93,9 +93,8 @@ public class GenerateReportActionTest
         RepositorySession repositorySession = mock( RepositorySession.class );
         when( repositorySession.getRepository() ).thenReturn( metadataRepository );
 
-        //TestRepositorySessionFactory factory = (TestRepositorySessionFactory) lookup( RepositorySessionFactory.class );
-
-        TestRepositorySessionFactory factory = new TestRepositorySessionFactory();
+        TestRepositorySessionFactory factory =
+            applicationContext.getBean( "repositorySessionFactory#test", TestRepositorySessionFactory.class );
         factory.setRepositorySession( repositorySession );
     }