james-server-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From btell...@apache.org
Subject james-project git commit: JAMES-1746 Provider needs the exact type implemented for junit-contracts reflexion
Date Fri, 10 Jun 2016 08:12:48 GMT
Repository: james-project
Updated Branches:
  refs/heads/master af7b1c63b -> 409c8cea6


JAMES-1746 Provider needs the exact type implemented for junit-contracts reflexion


Project: http://git-wip-us.apache.org/repos/asf/james-project/repo
Commit: http://git-wip-us.apache.org/repos/asf/james-project/commit/409c8cea
Tree: http://git-wip-us.apache.org/repos/asf/james-project/tree/409c8cea
Diff: http://git-wip-us.apache.org/repos/asf/james-project/diff/409c8cea

Branch: refs/heads/master
Commit: 409c8cea67dfabf6c6f86c3fd6c780c2d22bac04
Parents: af7b1c6
Author: Benoit Tellier <btellier@linagora.com>
Authored: Fri Jun 10 14:47:03 2016 +0700
Committer: Benoit Tellier <btellier@linagora.com>
Committed: Fri Jun 10 14:47:03 2016 +0700

----------------------------------------------------------------------
 .../mailbox/cassandra/CassandraMailboxManagerTest.java |  9 ++-------
 .../mailbox/cassandra/mail/CassandraMappersTests.java  |  5 ++---
 .../james/mailbox/hbase/HBaseMailboxManagerTest.java   |  5 ++---
 .../james/mailbox/jcr/JCRMailboxManagerTest.java       |  5 ++---
 .../james/mailbox/jpa/JPAMailboxManagerTest.java       |  5 ++---
 .../mailbox/maildir/MaildirMailboxManagerTests.java    | 13 ++++++-------
 .../mailbox/inmemory/InMemoryMailboxManagerTest.java   |  5 ++---
 .../mailbox/inmemory/mail/MemoryMappersTests.java      |  5 ++---
 .../access/CassandraAccessTokenRepositoryTest.java     |  5 ++---
 .../memory/access/MemoryAccessTokenRepositoryTest.java |  5 ++---
 10 files changed, 24 insertions(+), 38 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/james-project/blob/409c8cea/mailbox/cassandra/src/test/java/org/apache/james/mailbox/cassandra/CassandraMailboxManagerTest.java
----------------------------------------------------------------------
diff --git a/mailbox/cassandra/src/test/java/org/apache/james/mailbox/cassandra/CassandraMailboxManagerTest.java
b/mailbox/cassandra/src/test/java/org/apache/james/mailbox/cassandra/CassandraMailboxManagerTest.java
index e22595f..88387b1 100644
--- a/mailbox/cassandra/src/test/java/org/apache/james/mailbox/cassandra/CassandraMailboxManagerTest.java
+++ b/mailbox/cassandra/src/test/java/org/apache/james/mailbox/cassandra/CassandraMailboxManagerTest.java
@@ -20,7 +20,6 @@ package org.apache.james.mailbox.cassandra;
 
 import org.apache.james.backends.cassandra.CassandraCluster;
 import org.apache.james.backends.cassandra.init.CassandraModuleComposite;
-import org.apache.james.mailbox.MailboxManager;
 import org.apache.james.mailbox.cassandra.mail.CassandraModSeqProvider;
 import org.apache.james.mailbox.cassandra.mail.CassandraUidProvider;
 import org.apache.james.mailbox.cassandra.modules.CassandraAclModule;
@@ -42,10 +41,6 @@ import org.xenei.junit.contract.IProducer;
 
 import com.google.common.base.Throwables;
 
-/**
- * CassandraMailboxManagerTest that extends the StoreMailboxManagerTest.
- * 
- */
 @RunWith(ContractSuite.class)
 @ContractImpl(CassandraMailboxManager.class)
 public class CassandraMailboxManagerTest {
@@ -60,7 +55,7 @@ public class CassandraMailboxManagerTest {
         new CassandraSubscriptionModule(),
         new CassandraAttachmentModule()));
 
-    private IProducer<MailboxManager> producer = new IProducer<MailboxManager>()
{
+    private IProducer<CassandraMailboxManager> producer = new IProducer<CassandraMailboxManager>()
{
 
         @Override
         public CassandraMailboxManager newInstance() {
@@ -89,7 +84,7 @@ public class CassandraMailboxManagerTest {
     };
 
     @Contract.Inject
-    public IProducer<MailboxManager> getProducer() {
+    public IProducer<CassandraMailboxManager> getProducer() {
         return producer;
     }
 

http://git-wip-us.apache.org/repos/asf/james-project/blob/409c8cea/mailbox/cassandra/src/test/java/org/apache/james/mailbox/cassandra/mail/CassandraMappersTests.java
----------------------------------------------------------------------
diff --git a/mailbox/cassandra/src/test/java/org/apache/james/mailbox/cassandra/mail/CassandraMappersTests.java
b/mailbox/cassandra/src/test/java/org/apache/james/mailbox/cassandra/mail/CassandraMappersTests.java
index 205c886..9f37d64 100644
--- a/mailbox/cassandra/src/test/java/org/apache/james/mailbox/cassandra/mail/CassandraMappersTests.java
+++ b/mailbox/cassandra/src/test/java/org/apache/james/mailbox/cassandra/mail/CassandraMappersTests.java
@@ -20,7 +20,6 @@
 package org.apache.james.mailbox.cassandra.mail;
 
 import org.apache.james.mailbox.exception.MailboxException;
-import org.apache.james.mailbox.store.mail.model.MapperProvider;
 import org.junit.runner.RunWith;
 import org.xenei.junit.contract.Contract;
 import org.xenei.junit.contract.ContractImpl;
@@ -33,7 +32,7 @@ import com.google.common.base.Throwables;
 @ContractImpl(CassandraMapperProvider.class)
 public class CassandraMappersTests {
 
-    private IProducer<MapperProvider> producer = new IProducer<MapperProvider>()
{
+    private IProducer<CassandraMapperProvider> producer = new IProducer<CassandraMapperProvider>()
{
 
         private final CassandraMapperProvider cassandraMapperProvider = new CassandraMapperProvider();
 
@@ -53,7 +52,7 @@ public class CassandraMappersTests {
     };
 
     @Contract.Inject
-    public IProducer<MapperProvider> getProducer() {
+    public IProducer<CassandraMapperProvider> getProducer() {
         return producer;
     }
 

http://git-wip-us.apache.org/repos/asf/james-project/blob/409c8cea/mailbox/hbase/src/test/java/org/apache/james/mailbox/hbase/HBaseMailboxManagerTest.java
----------------------------------------------------------------------
diff --git a/mailbox/hbase/src/test/java/org/apache/james/mailbox/hbase/HBaseMailboxManagerTest.java
b/mailbox/hbase/src/test/java/org/apache/james/mailbox/hbase/HBaseMailboxManagerTest.java
index ae06d58..5c161fb 100644
--- a/mailbox/hbase/src/test/java/org/apache/james/mailbox/hbase/HBaseMailboxManagerTest.java
+++ b/mailbox/hbase/src/test/java/org/apache/james/mailbox/hbase/HBaseMailboxManagerTest.java
@@ -30,7 +30,6 @@ import static org.apache.james.mailbox.hbase.HBaseNames.SUBSCRIPTIONS;
 import static org.apache.james.mailbox.hbase.HBaseNames.SUBSCRIPTIONS_TABLE;
 import static org.apache.james.mailbox.hbase.HBaseNames.SUBSCRIPTION_CF;
 
-import org.apache.james.mailbox.MailboxManager;
 import org.apache.james.mailbox.acl.SimpleGroupMembershipResolver;
 import org.apache.james.mailbox.acl.UnionMailboxACLResolver;
 import org.apache.james.mailbox.exception.MailboxException;
@@ -51,7 +50,7 @@ public class HBaseMailboxManagerTest {
 
     private static final HBaseClusterSingleton CLUSTER = HBaseClusterSingleton.build();
 
-    private IProducer<MailboxManager> producer = new IProducer<MailboxManager>()
{
+    private IProducer<HBaseMailboxManager> producer = new IProducer<HBaseMailboxManager>()
{
 
         @Override
         public HBaseMailboxManager newInstance() {
@@ -86,7 +85,7 @@ public class HBaseMailboxManagerTest {
     };
 
     @Contract.Inject
-    public IProducer<MailboxManager> getProducer() {
+    public IProducer<HBaseMailboxManager> getProducer() {
         return producer;
     }
 

http://git-wip-us.apache.org/repos/asf/james-project/blob/409c8cea/mailbox/jcr/src/test/java/org/apache/james/mailbox/jcr/JCRMailboxManagerTest.java
----------------------------------------------------------------------
diff --git a/mailbox/jcr/src/test/java/org/apache/james/mailbox/jcr/JCRMailboxManagerTest.java
b/mailbox/jcr/src/test/java/org/apache/james/mailbox/jcr/JCRMailboxManagerTest.java
index e5a725b..4a4e6cf 100644
--- a/mailbox/jcr/src/test/java/org/apache/james/mailbox/jcr/JCRMailboxManagerTest.java
+++ b/mailbox/jcr/src/test/java/org/apache/james/mailbox/jcr/JCRMailboxManagerTest.java
@@ -29,7 +29,6 @@ import org.apache.commons.io.FileUtils;
 import org.apache.jackrabbit.core.RepositoryImpl;
 import org.apache.jackrabbit.core.config.ConfigurationException;
 import org.apache.jackrabbit.core.config.RepositoryConfig;
-import org.apache.james.mailbox.MailboxManager;
 import org.apache.james.mailbox.MailboxManagerTest;
 import org.apache.james.mailbox.acl.GroupMembershipResolver;
 import org.apache.james.mailbox.acl.MailboxACLResolver;
@@ -57,7 +56,7 @@ public class JCRMailboxManagerTest extends MailboxManagerTest {
 
     private static RepositoryImpl repository;
 
-    private IProducer<MailboxManager> producer = new IProducer<MailboxManager>()
{
+    private IProducer<JCRMailboxManager> producer = new IProducer<JCRMailboxManager>()
{
 
         @Override
         public JCRMailboxManager newInstance() {
@@ -111,7 +110,7 @@ public class JCRMailboxManagerTest extends MailboxManagerTest {
     };
 
     @Contract.Inject
-    public IProducer<MailboxManager> getProducer() {
+    public IProducer<JCRMailboxManager> getProducer() {
         return producer;
     }
 

http://git-wip-us.apache.org/repos/asf/james-project/blob/409c8cea/mailbox/jpa/src/test/java/org/apache/james/mailbox/jpa/JPAMailboxManagerTest.java
----------------------------------------------------------------------
diff --git a/mailbox/jpa/src/test/java/org/apache/james/mailbox/jpa/JPAMailboxManagerTest.java
b/mailbox/jpa/src/test/java/org/apache/james/mailbox/jpa/JPAMailboxManagerTest.java
index fb43b12..b8c583a 100644
--- a/mailbox/jpa/src/test/java/org/apache/james/mailbox/jpa/JPAMailboxManagerTest.java
+++ b/mailbox/jpa/src/test/java/org/apache/james/mailbox/jpa/JPAMailboxManagerTest.java
@@ -22,7 +22,6 @@ import java.util.HashMap;
 
 import javax.persistence.EntityManagerFactory;
 
-import org.apache.james.mailbox.MailboxManager;
 import org.apache.james.mailbox.MailboxSession;
 import org.apache.james.mailbox.acl.GroupMembershipResolver;
 import org.apache.james.mailbox.acl.MailboxACLResolver;
@@ -59,7 +58,7 @@ public class JPAMailboxManagerTest {
      */
     private static EntityManagerFactory entityManagerFactory;
 
-    private IProducer<MailboxManager> producer = new IProducer<MailboxManager>()
{
+    private IProducer<OpenJPAMailboxManager> producer = new IProducer<OpenJPAMailboxManager>()
{
 
         private OpenJPAMailboxManager openJPAMailboxManager;
 
@@ -112,7 +111,7 @@ public class JPAMailboxManagerTest {
     };
 
     @Contract.Inject
-    public IProducer<MailboxManager> getProducer() {
+    public IProducer<OpenJPAMailboxManager> getProducer() {
         return producer;
     }
 

http://git-wip-us.apache.org/repos/asf/james-project/blob/409c8cea/mailbox/maildir/src/test/java/org/apache/james/mailbox/maildir/MaildirMailboxManagerTests.java
----------------------------------------------------------------------
diff --git a/mailbox/maildir/src/test/java/org/apache/james/mailbox/maildir/MaildirMailboxManagerTests.java
b/mailbox/maildir/src/test/java/org/apache/james/mailbox/maildir/MaildirMailboxManagerTests.java
index 9a6a4a8..cd9c6c1 100644
--- a/mailbox/maildir/src/test/java/org/apache/james/mailbox/maildir/MaildirMailboxManagerTests.java
+++ b/mailbox/maildir/src/test/java/org/apache/james/mailbox/maildir/MaildirMailboxManagerTests.java
@@ -20,7 +20,6 @@ package org.apache.james.mailbox.maildir;
 
 import java.io.IOException;
 
-import org.apache.james.mailbox.MailboxManager;
 import org.apache.james.mailbox.MailboxManagerTest;
 import org.apache.james.mailbox.acl.GroupMembershipResolver;
 import org.apache.james.mailbox.acl.MailboxACLResolver;
@@ -71,7 +70,7 @@ public class MaildirMailboxManagerTests {
     public static class DomainUser extends MaildirMailboxManagerTest {
         @Rule public TemporaryFolder tmpFolder = new TemporaryFolder();
 
-        private IProducer<MailboxManager> producer = new IProducer<MailboxManager>()
{
+        private IProducer<StoreMailboxManager> producer = new IProducer<StoreMailboxManager>()
{
 
             @Override
             public StoreMailboxManager newInstance() {
@@ -90,7 +89,7 @@ public class MaildirMailboxManagerTests {
         };
 
         @Contract.Inject
-        public IProducer<MailboxManager> getProducer() {
+        public IProducer<StoreMailboxManager> getProducer() {
             return producer;
         }
     }
@@ -101,7 +100,7 @@ public class MaildirMailboxManagerTests {
     public static class User extends MaildirMailboxManagerTest {
         @Rule public TemporaryFolder tmpFolder = new TemporaryFolder();
 
-        private IProducer<MailboxManager> producer = new IProducer<MailboxManager>()
{
+        private IProducer<StoreMailboxManager> producer = new IProducer<StoreMailboxManager>()
{
 
             @Override
             public StoreMailboxManager newInstance() {
@@ -120,7 +119,7 @@ public class MaildirMailboxManagerTests {
         };
 
         @Contract.Inject
-        public IProducer<MailboxManager> getProducer() {
+        public IProducer<StoreMailboxManager> getProducer() {
             return producer;
         }
     }
@@ -130,7 +129,7 @@ public class MaildirMailboxManagerTests {
     public static class FullUser extends MaildirMailboxManagerTest {
         @Rule public TemporaryFolder tmpFolder = new TemporaryFolder();
 
-        private IProducer<MailboxManager> producer = new IProducer<MailboxManager>()
{
+        private IProducer<StoreMailboxManager> producer = new IProducer<StoreMailboxManager>()
{
 
             @Override
             public StoreMailboxManager newInstance() {
@@ -149,7 +148,7 @@ public class MaildirMailboxManagerTests {
         };
 
         @Contract.Inject
-        public IProducer<MailboxManager> getProducer() {
+        public IProducer<StoreMailboxManager> getProducer() {
             return producer;
         }
     }

http://git-wip-us.apache.org/repos/asf/james-project/blob/409c8cea/mailbox/memory/src/test/java/org/apache/james/mailbox/inmemory/InMemoryMailboxManagerTest.java
----------------------------------------------------------------------
diff --git a/mailbox/memory/src/test/java/org/apache/james/mailbox/inmemory/InMemoryMailboxManagerTest.java
b/mailbox/memory/src/test/java/org/apache/james/mailbox/inmemory/InMemoryMailboxManagerTest.java
index 7a9d836..e1b5007 100644
--- a/mailbox/memory/src/test/java/org/apache/james/mailbox/inmemory/InMemoryMailboxManagerTest.java
+++ b/mailbox/memory/src/test/java/org/apache/james/mailbox/inmemory/InMemoryMailboxManagerTest.java
@@ -19,7 +19,6 @@
 
 package org.apache.james.mailbox.inmemory;
 
-import org.apache.james.mailbox.MailboxManager;
 import org.apache.james.mailbox.acl.GroupMembershipResolver;
 import org.apache.james.mailbox.acl.MailboxACLResolver;
 import org.apache.james.mailbox.acl.SimpleGroupMembershipResolver;
@@ -40,7 +39,7 @@ import com.google.common.base.Throwables;
 @ContractImpl(InMemoryMailboxManager.class)
 public class InMemoryMailboxManagerTest {
 
-    private IProducer<MailboxManager> producer = new IProducer<MailboxManager>()
{
+    private IProducer<InMemoryMailboxManager> producer = new IProducer<InMemoryMailboxManager>()
{
 
         @Override
         public InMemoryMailboxManager newInstance() {
@@ -66,7 +65,7 @@ public class InMemoryMailboxManagerTest {
     };
 
     @Contract.Inject
-    public IProducer<MailboxManager> getProducer() {
+    public IProducer<InMemoryMailboxManager> getProducer() {
         return producer;
     }
     

http://git-wip-us.apache.org/repos/asf/james-project/blob/409c8cea/mailbox/memory/src/test/java/org/apache/james/mailbox/inmemory/mail/MemoryMappersTests.java
----------------------------------------------------------------------
diff --git a/mailbox/memory/src/test/java/org/apache/james/mailbox/inmemory/mail/MemoryMappersTests.java
b/mailbox/memory/src/test/java/org/apache/james/mailbox/inmemory/mail/MemoryMappersTests.java
index ca3af9a..099021b 100644
--- a/mailbox/memory/src/test/java/org/apache/james/mailbox/inmemory/mail/MemoryMappersTests.java
+++ b/mailbox/memory/src/test/java/org/apache/james/mailbox/inmemory/mail/MemoryMappersTests.java
@@ -20,7 +20,6 @@
 package org.apache.james.mailbox.inmemory.mail;
 
 import org.apache.james.mailbox.exception.MailboxException;
-import org.apache.james.mailbox.store.mail.model.MapperProvider;
 import org.junit.runner.RunWith;
 import org.xenei.junit.contract.Contract;
 import org.xenei.junit.contract.ContractImpl;
@@ -33,7 +32,7 @@ import com.google.common.base.Throwables;
 @ContractImpl(InMemoryMapperProvider.class)
 public class MemoryMappersTests {
 
-    private IProducer<MapperProvider> producer = new IProducer<MapperProvider>()
{
+    private IProducer<InMemoryMapperProvider> producer = new IProducer<InMemoryMapperProvider>()
{
 
         private final InMemoryMapperProvider mapperProvider = new InMemoryMapperProvider();
 
@@ -53,7 +52,7 @@ public class MemoryMappersTests {
     };
 
     @Contract.Inject
-    public IProducer<MapperProvider> getProducer() {
+    public IProducer<InMemoryMapperProvider> getProducer() {
         return producer;
     }
 

http://git-wip-us.apache.org/repos/asf/james-project/blob/409c8cea/server/data/data-jmap-cassandra/src/test/java/org/apache/james/jmap/cassandra/access/CassandraAccessTokenRepositoryTest.java
----------------------------------------------------------------------
diff --git a/server/data/data-jmap-cassandra/src/test/java/org/apache/james/jmap/cassandra/access/CassandraAccessTokenRepositoryTest.java
b/server/data/data-jmap-cassandra/src/test/java/org/apache/james/jmap/cassandra/access/CassandraAccessTokenRepositoryTest.java
index ccb44c4..20b332f 100644
--- a/server/data/data-jmap-cassandra/src/test/java/org/apache/james/jmap/cassandra/access/CassandraAccessTokenRepositoryTest.java
+++ b/server/data/data-jmap-cassandra/src/test/java/org/apache/james/jmap/cassandra/access/CassandraAccessTokenRepositoryTest.java
@@ -20,7 +20,6 @@
 package org.apache.james.jmap.cassandra.access;
 
 import org.apache.james.backends.cassandra.CassandraCluster;
-import org.apache.james.jmap.api.access.AccessTokenRepository;
 import org.apache.james.jmap.api.access.AccessTokenRepositoryTest;
 import org.junit.runner.RunWith;
 import org.xenei.junit.contract.Contract;
@@ -32,7 +31,7 @@ import org.xenei.junit.contract.IProducer;
 @ContractImpl(CassandraAccessTokenRepository.class)
 public class CassandraAccessTokenRepositoryTest {
 
-    private IProducer<AccessTokenRepository> producer = new IProducer<AccessTokenRepository>()
{
+    private IProducer<CassandraAccessTokenRepository> producer = new IProducer<CassandraAccessTokenRepository>()
{
 
         private CassandraCluster cassandra;
 
@@ -49,7 +48,7 @@ public class CassandraAccessTokenRepositoryTest {
     };
 
     @Contract.Inject
-    public IProducer<AccessTokenRepository> getProducer() {
+    public IProducer<CassandraAccessTokenRepository> getProducer() {
         return producer;
     }
 }

http://git-wip-us.apache.org/repos/asf/james-project/blob/409c8cea/server/data/data-jmap/src/test/java/org/apache/james/jmap/memory/access/MemoryAccessTokenRepositoryTest.java
----------------------------------------------------------------------
diff --git a/server/data/data-jmap/src/test/java/org/apache/james/jmap/memory/access/MemoryAccessTokenRepositoryTest.java
b/server/data/data-jmap/src/test/java/org/apache/james/jmap/memory/access/MemoryAccessTokenRepositoryTest.java
index c40ab39..8949a48 100644
--- a/server/data/data-jmap/src/test/java/org/apache/james/jmap/memory/access/MemoryAccessTokenRepositoryTest.java
+++ b/server/data/data-jmap/src/test/java/org/apache/james/jmap/memory/access/MemoryAccessTokenRepositoryTest.java
@@ -19,7 +19,6 @@
 
 package org.apache.james.jmap.memory.access;
 
-import org.apache.james.jmap.api.access.AccessTokenRepository;
 import org.apache.james.jmap.api.access.AccessTokenRepositoryTest;
 import org.junit.runner.RunWith;
 import org.xenei.junit.contract.Contract;
@@ -31,7 +30,7 @@ import org.xenei.junit.contract.IProducer;
 @ContractImpl(MemoryAccessTokenRepository.class)
 public class MemoryAccessTokenRepositoryTest {
 
-    private IProducer<AccessTokenRepository> producer = new IProducer<AccessTokenRepository>()
{
+    private IProducer<MemoryAccessTokenRepository> producer = new IProducer<MemoryAccessTokenRepository>()
{
         @Override
         public MemoryAccessTokenRepository newInstance() {
             return new MemoryAccessTokenRepository(AccessTokenRepositoryTest.TTL_IN_MS);
@@ -44,7 +43,7 @@ public class MemoryAccessTokenRepositoryTest {
     };
 
     @Contract.Inject
-    public IProducer<AccessTokenRepository> getProducer() {
+    public IProducer<MemoryAccessTokenRepository> getProducer() {
         return producer;
     }
 


---------------------------------------------------------------------
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