james-server-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From e...@apache.org
Subject svn commit: r1003409 - /james/imap/trunk/jpa/src/test/java/org/apache/james/mailbox/jpa/JPAStressTest.java
Date Fri, 01 Oct 2010 07:12:55 GMT
Author: eric
Date: Fri Oct  1 07:12:55 2010
New Revision: 1003409

URL: http://svn.apache.org/viewvc?rev=1003409&view=rev
Log:
Enforce JPAHeader class name.

Modified:
    james/imap/trunk/jpa/src/test/java/org/apache/james/mailbox/jpa/JPAStressTest.java

Modified: james/imap/trunk/jpa/src/test/java/org/apache/james/mailbox/jpa/JPAStressTest.java
URL: http://svn.apache.org/viewvc/james/imap/trunk/jpa/src/test/java/org/apache/james/mailbox/jpa/JPAStressTest.java?rev=1003409&r1=1003408&r2=1003409&view=diff
==============================================================================
--- james/imap/trunk/jpa/src/test/java/org/apache/james/mailbox/jpa/JPAStressTest.java (original)
+++ james/imap/trunk/jpa/src/test/java/org/apache/james/mailbox/jpa/JPAStressTest.java Fri
Oct  1 07:12:55 2010
@@ -28,7 +28,7 @@ import org.apache.james.imap.functional.
 import org.apache.james.mailbox.MailboxException;
 import org.apache.james.mailbox.MailboxManager;
 import org.apache.james.mailbox.MailboxSession;
-import org.apache.james.mailbox.jpa.JPAMailboxSessionMapperFactory;
+import org.apache.james.mailbox.jpa.mail.model.JPAHeader;
 import org.apache.james.mailbox.jpa.mail.model.JPAMailbox;
 import org.apache.james.mailbox.jpa.mail.model.JPAProperty;
 import org.apache.james.mailbox.jpa.mail.model.openjpa.AbstractJPAMailboxMembership;
@@ -45,21 +45,24 @@ import org.junit.Before;
  * Proof of bug https://issues.apache.org/jira/browse/IMAP-137
  */
 public class JPAStressTest extends AbstractStressTest{
-
     
     private OpenJPAMailboxManager mailboxManager;
+    
     private long locktimeout = 60000;
+    
     private EntityManagerFactory entityManagerFactory;
     
     @Before
     public void setUp() {
+        
         HashMap<String, String> properties = new HashMap<String, String>();
         properties.put("openjpa.ConnectionDriverName", "org.h2.Driver");
         properties.put("openjpa.ConnectionURL", "jdbc:h2:mem:imap;DB_CLOSE_DELAY=-1");
         properties.put("openjpa.Log", "JDBC=WARN, SQL=WARN, Runtime=WARN");
         properties.put("openjpa.ConnectionFactoryProperties", "PrettyPrint=true, PrettyPrintLineLength=72");
         properties.put("openjpa.jdbc.SynchronizeMappings", "buildSchema(ForeignKeys=true)");
-        properties.put("openjpa.MetaDataFactory", "jpa(Types=org.apache.james.mailbox.jpa.mail.model.JPAHeader;"
+
+        properties.put("openjpa.MetaDataFactory", "jpa(Types=" +
+                JPAHeader.class.getName() + ";" +
                 JPAMailbox.class.getName() + ";" +
                 AbstractJPAMailboxMembership.class.getName() + ";" +
                 JPAMailboxMembership.class.getName() + ";" +
@@ -76,9 +79,9 @@ public class JPAStressTest extends Abstr
         // Set the lock timeout via SQL because of a bug in openJPA
         // https://issues.apache.org/jira/browse/OPENJPA-1656
         setH2LockTimeout();
+    
     }
     
- 
     private void setH2LockTimeout() {
         EntityManager manager = entityManagerFactory.createEntityManager();
         manager.getTransaction().begin();
@@ -87,7 +90,6 @@ public class JPAStressTest extends Abstr
         manager.close();
     }
     
-    
     @After
     public void tearDown() {
         MailboxSession session = mailboxManager.createSystemSession("test", new SimpleLog("Test"));



---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org


Mime
View raw message