[seam-commits] Seam SVN: r14839 - branches/community/Seam_2_3/jboss-seam/src/main/java/org/jboss/seam/mock.

seam-commits at lists.jboss.org seam-commits at lists.jboss.org
Wed Jun 6 10:21:12 EDT 2012


Author: maschmid
Date: 2012-06-06 10:21:12 -0400 (Wed, 06 Jun 2012)
New Revision: 14839

Modified:
   branches/community/Seam_2_3/jboss-seam/src/main/java/org/jboss/seam/mock/AbstractSeamTest.java
Log:
JBSEAM-4986 attempt to fix it by not using FactoryFinder to get the MockApplication instance


Modified: branches/community/Seam_2_3/jboss-seam/src/main/java/org/jboss/seam/mock/AbstractSeamTest.java
===================================================================
--- branches/community/Seam_2_3/jboss-seam/src/main/java/org/jboss/seam/mock/AbstractSeamTest.java	2012-06-05 22:18:31 UTC (rev 14838)
+++ branches/community/Seam_2_3/jboss-seam/src/main/java/org/jboss/seam/mock/AbstractSeamTest.java	2012-06-06 14:21:12 UTC (rev 14839)
@@ -987,7 +987,11 @@
    protected void setupClass() throws Exception
    {
       servletContext = ServletLifecycle.getServletContext();
-      applicationFactory = (ApplicationFactory) FactoryFinder.getFactory(FactoryFinder.APPLICATION_FACTORY);
+      
+      // FactoryFinder cannot be reliably used, as something could have called getFactory sooner
+      //applicationFactory = (ApplicationFactory) FactoryFinder.getFactory(FactoryFinder.APPLICATION_FACTORY);
+      applicationFactory = new MockApplicationFactory();
+      
       application = applicationFactory.getApplication();
       conversationViewRootAttributes = new HashMap<String, Map>();
       seamFilter = createSeamFilter();



More information about the seam-commits mailing list