From 56c4de95b08aa888fae4a397d2c0dc0ce5fbcc76 Mon Sep 17 00:00:00 2001
From: "Endi S. Dewata" <edewata@redhat.com>
Date: Thu, 15 Aug 2013 19:16:04 -0400
Subject: [PATCH] Fixed tests dependencies.

The test classes have been moved from base/common/test to base/server/test
and into the cmscore package because they are dependent on server classes.
---
 .classpath                                          |  2 +-
 base/common/CMakeLists.txt                          |  1 -
 .../netscape/certsrv/request/AgentApprovals.java    | 13 +++++++++++--
 base/server/CMakeLists.txt                          |  1 +
 base/{common => server}/test/CMakeLists.txt         | 15 +++++++--------
 .../netscape/cmscore}/app/CMSEngineDefaultStub.java |  2 +-
 .../cmscore}/authentication/AuthTokenTest.java      | 17 +++++++++--------
 .../netscape/cmscore/dbs/CertRecordListTest.java    |  0
 .../netscape/cmscore/dbs/DBRegistryDefaultStub.java |  0
 .../com/netscape/cmscore/dbs/DBRegistryTest.java    |  0
 .../netscape/cmscore/dbs/DBSSessionDefaultStub.java |  0
 .../cmscore/dbs/DBSubsystemDefaultStub.java         |  0
 .../cmscore/dbs/DBVirtualListDefaultStub.java       |  0
 .../cmscore/dbs/RequestRecordDefaultStub.java       |  0
 .../cmscore}/logging/LoggerDefaultStub.java         |  7 ++++++-
 .../cmscore}/request/AgentApprovalsTest.java        | 21 ++++++++++-----------
 .../cmscore/request/DBDynAttrMapperDefaultStub.java |  0
 .../cmscore/request/ExtAttrDynMapperTest.java       |  0
 .../cmscore/request/ExtDataHashtableTest.java       |  0
 .../cmscore/request/RequestDefaultStub.java         |  0
 .../cmscore/request/RequestModDefaultStub.java      |  0
 .../netscape/cmscore/request/RequestQueueTest.java  |  0
 .../netscape/cmscore/request/RequestRecordTest.java |  0
 .../com/netscape/cmscore/request/RequestTest.java   |  2 +-
 .../com/netscape/cmscore/test/CMSBaseTestCase.java  |  4 ++--
 .../test/com/netscape/cmscore/test/TestHelper.java  |  0
 26 files changed, 49 insertions(+), 36 deletions(-)
 rename base/{common => server}/test/CMakeLists.txt (86%)
 rename base/{common/test/com/netscape/certsrv => server/test/com/netscape/cmscore}/app/CMSEngineDefaultStub.java (99%)
 rename base/{common/test/com/netscape/certsrv => server/test/com/netscape/cmscore}/authentication/AuthTokenTest.java (95%)
 rename base/{common => server}/test/com/netscape/cmscore/dbs/CertRecordListTest.java (100%)
 rename base/{common => server}/test/com/netscape/cmscore/dbs/DBRegistryDefaultStub.java (100%)
 rename base/{common => server}/test/com/netscape/cmscore/dbs/DBRegistryTest.java (100%)
 rename base/{common => server}/test/com/netscape/cmscore/dbs/DBSSessionDefaultStub.java (100%)
 rename base/{common => server}/test/com/netscape/cmscore/dbs/DBSubsystemDefaultStub.java (100%)
 rename base/{common => server}/test/com/netscape/cmscore/dbs/DBVirtualListDefaultStub.java (100%)
 rename base/{common => server}/test/com/netscape/cmscore/dbs/RequestRecordDefaultStub.java (100%)
 rename base/{common/test/com/netscape/certsrv => server/test/com/netscape/cmscore}/logging/LoggerDefaultStub.java (90%)
 rename base/{common/test/com/netscape/certsrv => server/test/com/netscape/cmscore}/request/AgentApprovalsTest.java (80%)
 rename base/{common => server}/test/com/netscape/cmscore/request/DBDynAttrMapperDefaultStub.java (100%)
 rename base/{common => server}/test/com/netscape/cmscore/request/ExtAttrDynMapperTest.java (100%)
 rename base/{common => server}/test/com/netscape/cmscore/request/ExtDataHashtableTest.java (100%)
 rename base/{common => server}/test/com/netscape/cmscore/request/RequestDefaultStub.java (100%)
 rename base/{common => server}/test/com/netscape/cmscore/request/RequestModDefaultStub.java (100%)
 rename base/{common => server}/test/com/netscape/cmscore/request/RequestQueueTest.java (100%)
 rename base/{common => server}/test/com/netscape/cmscore/request/RequestRecordTest.java (100%)
 rename base/{common => server}/test/com/netscape/cmscore/request/RequestTest.java (99%)
 rename base/{common => server}/test/com/netscape/cmscore/test/CMSBaseTestCase.java (97%)
 rename base/{common => server}/test/com/netscape/cmscore/test/TestHelper.java (100%)

diff --git a/.classpath b/.classpath
index 5161a988a3bb038ce688a81059f7c64a8af0fcc2..f34b318ca7bbdf936e224a3565506c43372b5a5e 100644
--- a/.classpath
+++ b/.classpath
@@ -5,12 +5,12 @@
 	<classpathentry excluding="**/CMakeLists.txt" kind="src" path="base/util/src"/>
 	<classpathentry excluding="**/CMakeLists.txt" kind="src" path="base/util/test"/>
 	<classpathentry excluding="**/CMakeLists.txt" kind="src" path="base/common/src"/>
-	<classpathentry excluding="**/CMakeLists.txt" kind="src" path="base/common/test"/>
 	<classpathentry excluding="**/CMakeLists.txt" kind="src" path="base/common/functional/src"/>
 	<classpathentry excluding="**/CMakeLists.txt" kind="src" path="base/java-tools/src"/>
 	<classpathentry excluding="**/CMakeLists.txt" kind="src" path="base/server/tomcat/src"/>
 	<classpathentry excluding="**/CMakeLists.txt" kind="src" path="base/server/cms/src"/>
 	<classpathentry excluding="**/CMakeLists.txt" kind="src" path="base/server/cmscore/src"/>
+	<classpathentry excluding="**/CMakeLists.txt" kind="src" path="base/server/test"/>
 	<classpathentry excluding="**/CMakeLists.txt" kind="src" path="base/silent/src"/>
 	<classpathentry excluding="**/CMakeLists.txt" kind="src" path="base/ca/src"/>
 	<classpathentry excluding="**/CMakeLists.txt" kind="src" path="base/ca/functional/src"/>
diff --git a/base/common/CMakeLists.txt b/base/common/CMakeLists.txt
index 1c6ef9b54cc07566cdb549fc0b70ae7c50bd3b8a..1094be0c535b527061e4beefa8b0fbd8efe8a31f 100644
--- a/base/common/CMakeLists.txt
+++ b/base/common/CMakeLists.txt
@@ -88,4 +88,3 @@ install(
 )
 
 add_subdirectory(src)
-add_subdirectory(test)
diff --git a/base/common/src/com/netscape/certsrv/request/AgentApprovals.java b/base/common/src/com/netscape/certsrv/request/AgentApprovals.java
index cb3dd2ceb815609ddaebff0b524dffb9ece98b22..e778837cfcf9ae9a5fbf167574471bdbd410e6dd 100644
--- a/base/common/src/com/netscape/certsrv/request/AgentApprovals.java
+++ b/base/common/src/com/netscape/certsrv/request/AgentApprovals.java
@@ -44,17 +44,18 @@ public class AgentApprovals
      *
      * @param userName user name of the approving agent
      */
-    public void addApproval(String userName) {
+    public AgentApproval addApproval(String userName) {
         AgentApproval a = findApproval(userName);
 
         // update existing approval
         if (a != null) {
             a.mDate = new Date(); /* CMS.getCurrentDate(); */
-            return;
+            return a;
         }
 
         a = new AgentApproval(userName);
         mVector.addElement(a);
+        return a;
     }
 
     /**
@@ -155,5 +156,13 @@ public class AgentApprovals
         return approvals;
     }
 
+    public int size() {
+        return mVector.size();
+    }
+
+    public AgentApproval get(int i) {
+        return mVector.get(i);
+    }
+
     protected Vector<AgentApproval> mVector = new Vector<AgentApproval>();
 }
diff --git a/base/server/CMakeLists.txt b/base/server/CMakeLists.txt
index 8f1391a73e3f5c4f6719a34091ad4757f9b99c96..5250ff3a67882ee16acaa452982f8c6338ea4308 100644
--- a/base/server/CMakeLists.txt
+++ b/base/server/CMakeLists.txt
@@ -143,3 +143,4 @@ install(CODE "file(MAKE_DIRECTORY \$ENV{DESTDIR}${VAR_INSTALL_DIR}/run/pki)")
 add_subdirectory(tomcat)
 add_subdirectory(cms)
 add_subdirectory(cmscore)
+add_subdirectory(test)
diff --git a/base/common/test/CMakeLists.txt b/base/server/test/CMakeLists.txt
similarity index 86%
rename from base/common/test/CMakeLists.txt
rename to base/server/test/CMakeLists.txt
index 7001cfe42f8d36fc1a831799273884c9983bdd42..ff359b2a8027cee706c0aa5bd37c939fc8f3cad4 100644
--- a/base/common/test/CMakeLists.txt
+++ b/base/server/test/CMakeLists.txt
@@ -1,4 +1,4 @@
-project(pki-common-test NONE)
+project(pki-server-test NONE)
 
 find_file(PKI_CERTSRV_JAR
     NAMES
@@ -28,11 +28,10 @@ find_file(PKI_CMSBUNDLE_JAR
         ${JAVA_JAR_INSTALL_DIR}/pki
 )
 
-# build pki-common-test
+# build pki-server-test
 # TODO: build test only when the test is invoked
-javac(pki-common-test-classes
+javac(pki-server-test-classes
     SOURCES
-        com/netscape/certsrv/*.java
         com/netscape/cmscore/*.java
     CLASSPATH
         ${PKI_NSUTIL_JAR} ${PKI_CMSUTIL_JAR}
@@ -51,7 +50,7 @@ javac(pki-common-test-classes
 # create test target
 # do not include xalan and xerces in class path
 # TODO: create CMake function to find all JUnit test classes
-add_junit_test(test-pki-common
+add_junit_test(test-pki-server
     CLASSPATH
         ${PKI_NSUTIL_JAR} ${PKI_CMSUTIL_JAR}
         ${PKI_CERTSRV_JAR} ${PKI_CMS_JAR} ${PKI_CMSCORE_JAR} ${PKI_CMSBUNDLE_JAR}
@@ -59,10 +58,10 @@ add_junit_test(test-pki-common
         ${JSS_JAR} ${COMMONS_CODEC_JAR} ${SYMKEY_JAR} ${JUNIT_JAR}
         ${CMAKE_BINARY_DIR}/test/classes
     TESTS
-        com.netscape.certsrv.authentication.AuthTokenTest
-        com.netscape.certsrv.request.AgentApprovalsTest
+        com.netscape.cmscore.authentication.AuthTokenTest
         com.netscape.cmscore.dbs.CertRecordListTest
         com.netscape.cmscore.dbs.DBRegistryTest
+        com.netscape.cmscore.request.AgentApprovalsTest
         com.netscape.cmscore.request.ExtAttrDynMapperTest
         com.netscape.cmscore.request.ExtDataHashtableTest
         com.netscape.cmscore.request.RequestQueueTest
@@ -73,4 +72,4 @@ add_junit_test(test-pki-common
 )
 
 # include test into the main test
-add_dependencies(test test-pki-common)
+add_dependencies(test test-pki-server)
diff --git a/base/common/test/com/netscape/certsrv/app/CMSEngineDefaultStub.java b/base/server/test/com/netscape/cmscore/app/CMSEngineDefaultStub.java
similarity index 99%
rename from base/common/test/com/netscape/certsrv/app/CMSEngineDefaultStub.java
rename to base/server/test/com/netscape/cmscore/app/CMSEngineDefaultStub.java
index dbd27c914bd47b983e5d25427d17e76add2b617c..1e0310e5cf449d6895f5957928c5482107c48d06 100644
--- a/base/common/test/com/netscape/certsrv/app/CMSEngineDefaultStub.java
+++ b/base/server/test/com/netscape/cmscore/app/CMSEngineDefaultStub.java
@@ -1,4 +1,4 @@
-package com.netscape.certsrv.app;
+package com.netscape.cmscore.app;
 
 import java.math.BigInteger;
 import java.security.NoSuchAlgorithmException;
diff --git a/base/common/test/com/netscape/certsrv/authentication/AuthTokenTest.java b/base/server/test/com/netscape/cmscore/authentication/AuthTokenTest.java
similarity index 95%
rename from base/common/test/com/netscape/certsrv/authentication/AuthTokenTest.java
rename to base/server/test/com/netscape/cmscore/authentication/AuthTokenTest.java
index 338ae5e1e3001f007f08ce79a3370741a8546a92..f4ca9f755c95bfd7793e05c537c14d4b8a8eab23 100644
--- a/base/common/test/com/netscape/certsrv/authentication/AuthTokenTest.java
+++ b/base/server/test/com/netscape/cmscore/authentication/AuthTokenTest.java
@@ -1,4 +1,4 @@
-package com.netscape.certsrv.authentication;
+package com.netscape.cmscore.authentication;
 
 import java.io.IOException;
 import java.math.BigInteger;
@@ -14,9 +14,10 @@ import netscape.security.x509.CertificateExtensions;
 import netscape.security.x509.PKIXExtensions;
 import netscape.security.x509.X509CertImpl;
 
-import com.netscape.certsrv.app.CMSEngineDefaultStub;
 import com.netscape.certsrv.apps.CMS;
+import com.netscape.certsrv.authentication.AuthToken;
 import com.netscape.certsrv.usrgrp.Certificates;
+import com.netscape.cmscore.app.CMSEngineDefaultStub;
 import com.netscape.cmscore.test.CMSBaseTestCase;
 
 public class AuthTokenTest extends CMSBaseTestCase {
@@ -45,7 +46,7 @@ public class AuthTokenTest extends CMSBaseTestCase {
 
     public void testGetSetString() {
         authToken.set("key", "value");
-        assertEquals("value", authToken.mAttrs.get("key"));
+        assertEquals("value", authToken.get("key"));
         assertEquals("value", authToken.getInString("key"));
 
         assertFalse(authToken.set("key", (String) null));
@@ -67,7 +68,7 @@ public class AuthTokenTest extends CMSBaseTestCase {
 
     public void testGetSetInteger() {
         authToken.set("key", Integer.valueOf(432));
-        assertEquals("432", authToken.mAttrs.get("key"));
+        assertEquals("432", authToken.get("key"));
         assertEquals(Integer.valueOf(432), authToken.getInInteger("key"));
 
         assertNull(authToken.getInInteger("notfound"));
@@ -86,7 +87,7 @@ public class AuthTokenTest extends CMSBaseTestCase {
         };
         authToken.set("key", data);
         assertEquals("111111111,222222222,333333333",
-                authToken.mAttrs.get("key"));
+                authToken.get("key"));
         BigInteger[] retval = authToken.getInBigIntegerArray("key");
         assertEquals(3, retval.length);
         assertEquals(data[0], retval[0]);
@@ -113,7 +114,7 @@ public class AuthTokenTest extends CMSBaseTestCase {
         Date value = new Date();
         authToken.set("key", value);
         assertEquals(String.valueOf(value.getTime()),
-                authToken.mAttrs.get("key"));
+                authToken.get("key"));
         assertEquals(value, authToken.getInDate("key"));
 
         authToken.set("key2", "234567");
@@ -185,7 +186,7 @@ public class AuthTokenTest extends CMSBaseTestCase {
         BasicConstraintsExtension ext = new BasicConstraintsExtension(false, 1);
 
         assertTrue(authToken.set("key", certExts));
-        assertTrue(authToken.mAttrs.containsKey("key"));
+        assertNotNull(authToken.get("key"));
         CertificateExtensions retval = authToken.getInCertExts("key");
         assertNotNull(retval);
         assertEquals(0, retval.size());
@@ -194,7 +195,7 @@ public class AuthTokenTest extends CMSBaseTestCase {
         assertTrue(authToken.set("key2", certExts));
 
         retval = authToken.getInCertExts("key2");
-        assertTrue(authToken.mAttrs.containsKey("key2"));
+        assertNotNull(authToken.get("key2"));
         assertNotNull(retval);
         assertEquals(1, retval.size());
 
diff --git a/base/common/test/com/netscape/cmscore/dbs/CertRecordListTest.java b/base/server/test/com/netscape/cmscore/dbs/CertRecordListTest.java
similarity index 100%
rename from base/common/test/com/netscape/cmscore/dbs/CertRecordListTest.java
rename to base/server/test/com/netscape/cmscore/dbs/CertRecordListTest.java
diff --git a/base/common/test/com/netscape/cmscore/dbs/DBRegistryDefaultStub.java b/base/server/test/com/netscape/cmscore/dbs/DBRegistryDefaultStub.java
similarity index 100%
rename from base/common/test/com/netscape/cmscore/dbs/DBRegistryDefaultStub.java
rename to base/server/test/com/netscape/cmscore/dbs/DBRegistryDefaultStub.java
diff --git a/base/common/test/com/netscape/cmscore/dbs/DBRegistryTest.java b/base/server/test/com/netscape/cmscore/dbs/DBRegistryTest.java
similarity index 100%
rename from base/common/test/com/netscape/cmscore/dbs/DBRegistryTest.java
rename to base/server/test/com/netscape/cmscore/dbs/DBRegistryTest.java
diff --git a/base/common/test/com/netscape/cmscore/dbs/DBSSessionDefaultStub.java b/base/server/test/com/netscape/cmscore/dbs/DBSSessionDefaultStub.java
similarity index 100%
rename from base/common/test/com/netscape/cmscore/dbs/DBSSessionDefaultStub.java
rename to base/server/test/com/netscape/cmscore/dbs/DBSSessionDefaultStub.java
diff --git a/base/common/test/com/netscape/cmscore/dbs/DBSubsystemDefaultStub.java b/base/server/test/com/netscape/cmscore/dbs/DBSubsystemDefaultStub.java
similarity index 100%
rename from base/common/test/com/netscape/cmscore/dbs/DBSubsystemDefaultStub.java
rename to base/server/test/com/netscape/cmscore/dbs/DBSubsystemDefaultStub.java
diff --git a/base/common/test/com/netscape/cmscore/dbs/DBVirtualListDefaultStub.java b/base/server/test/com/netscape/cmscore/dbs/DBVirtualListDefaultStub.java
similarity index 100%
rename from base/common/test/com/netscape/cmscore/dbs/DBVirtualListDefaultStub.java
rename to base/server/test/com/netscape/cmscore/dbs/DBVirtualListDefaultStub.java
diff --git a/base/common/test/com/netscape/cmscore/dbs/RequestRecordDefaultStub.java b/base/server/test/com/netscape/cmscore/dbs/RequestRecordDefaultStub.java
similarity index 100%
rename from base/common/test/com/netscape/cmscore/dbs/RequestRecordDefaultStub.java
rename to base/server/test/com/netscape/cmscore/dbs/RequestRecordDefaultStub.java
diff --git a/base/common/test/com/netscape/certsrv/logging/LoggerDefaultStub.java b/base/server/test/com/netscape/cmscore/logging/LoggerDefaultStub.java
similarity index 90%
rename from base/common/test/com/netscape/certsrv/logging/LoggerDefaultStub.java
rename to base/server/test/com/netscape/cmscore/logging/LoggerDefaultStub.java
index c136c7feb8c7219bf3c89bbd677a003659fd81f3..2e558ea5390a3bf77b966bac30a46f8802f0a546 100644
--- a/base/common/test/com/netscape/certsrv/logging/LoggerDefaultStub.java
+++ b/base/server/test/com/netscape/cmscore/logging/LoggerDefaultStub.java
@@ -1,7 +1,12 @@
-package com.netscape.certsrv.logging;
+package com.netscape.cmscore.logging;
 
 import java.util.Properties;
 
+import com.netscape.certsrv.logging.ILogEvent;
+import com.netscape.certsrv.logging.ILogEventFactory;
+import com.netscape.certsrv.logging.ILogQueue;
+import com.netscape.certsrv.logging.ILogger;
+
 /**
  * Default logging stub for testing.
  */
diff --git a/base/common/test/com/netscape/certsrv/request/AgentApprovalsTest.java b/base/server/test/com/netscape/cmscore/request/AgentApprovalsTest.java
similarity index 80%
rename from base/common/test/com/netscape/certsrv/request/AgentApprovalsTest.java
rename to base/server/test/com/netscape/cmscore/request/AgentApprovalsTest.java
index dbb4c189fe6b2516a6251e639832c1df12bc34b4..55695f3400b574c839eed7b2424130c7e16c30d0 100644
--- a/base/common/test/com/netscape/certsrv/request/AgentApprovalsTest.java
+++ b/base/server/test/com/netscape/cmscore/request/AgentApprovalsTest.java
@@ -1,10 +1,12 @@
-package com.netscape.certsrv.request;
+package com.netscape.cmscore.request;
 
 import java.util.Vector;
 
 import junit.framework.Test;
 import junit.framework.TestSuite;
 
+import com.netscape.certsrv.request.AgentApproval;
+import com.netscape.certsrv.request.AgentApprovals;
 import com.netscape.cmscore.test.CMSBaseTestCase;
 
 public class AgentApprovalsTest extends CMSBaseTestCase {
@@ -27,12 +29,9 @@ public class AgentApprovalsTest extends CMSBaseTestCase {
     }
 
     public void testToFromStringVector() {
-        AgentApproval approval1 = new AgentApproval("user1");
-        AgentApproval approval2 = new AgentApproval("user2");
-        AgentApproval approval3 = new AgentApproval(";user4;messy name");
-        agentApprovals.mVector.add(approval1);
-        agentApprovals.mVector.add(approval2);
-        agentApprovals.mVector.add(approval3);
+        AgentApproval approval1 = agentApprovals.addApproval("user1");
+        AgentApproval approval2 = agentApprovals.addApproval("user2");
+        AgentApproval approval3 = agentApprovals.addApproval(";user4;messy name");
 
         Vector<String> stringVector = agentApprovals.toStringVector();
         assertNotNull(stringVector);
@@ -46,17 +45,17 @@ public class AgentApprovalsTest extends CMSBaseTestCase {
 
         AgentApprovals approvals = AgentApprovals.fromStringVector(stringVector);
         assertNotNull(approvals);
-        assertEquals(3, approvals.mVector.size());
+        assertEquals(3, approvals.size());
 
-        AgentApproval approval = approvals.mVector.get(0);
+        AgentApproval approval = approvals.get(0);
         assertEquals(approval1.getUserName(), approval.getUserName());
         assertEquals(approval1.getDate(), approval.getDate());
 
-        approval = approvals.mVector.get(1);
+        approval = approvals.get(1);
         assertEquals(approval2.getUserName(), approval.getUserName());
         assertEquals(approval2.getDate(), approval.getDate());
 
-        approval = approvals.mVector.get(2);
+        approval = approvals.get(2);
         assertEquals(approval3.getUserName(), approval.getUserName());
         assertEquals(approval3.getDate(), approval.getDate());
 
diff --git a/base/common/test/com/netscape/cmscore/request/DBDynAttrMapperDefaultStub.java b/base/server/test/com/netscape/cmscore/request/DBDynAttrMapperDefaultStub.java
similarity index 100%
rename from base/common/test/com/netscape/cmscore/request/DBDynAttrMapperDefaultStub.java
rename to base/server/test/com/netscape/cmscore/request/DBDynAttrMapperDefaultStub.java
diff --git a/base/common/test/com/netscape/cmscore/request/ExtAttrDynMapperTest.java b/base/server/test/com/netscape/cmscore/request/ExtAttrDynMapperTest.java
similarity index 100%
rename from base/common/test/com/netscape/cmscore/request/ExtAttrDynMapperTest.java
rename to base/server/test/com/netscape/cmscore/request/ExtAttrDynMapperTest.java
diff --git a/base/common/test/com/netscape/cmscore/request/ExtDataHashtableTest.java b/base/server/test/com/netscape/cmscore/request/ExtDataHashtableTest.java
similarity index 100%
rename from base/common/test/com/netscape/cmscore/request/ExtDataHashtableTest.java
rename to base/server/test/com/netscape/cmscore/request/ExtDataHashtableTest.java
diff --git a/base/common/test/com/netscape/cmscore/request/RequestDefaultStub.java b/base/server/test/com/netscape/cmscore/request/RequestDefaultStub.java
similarity index 100%
rename from base/common/test/com/netscape/cmscore/request/RequestDefaultStub.java
rename to base/server/test/com/netscape/cmscore/request/RequestDefaultStub.java
diff --git a/base/common/test/com/netscape/cmscore/request/RequestModDefaultStub.java b/base/server/test/com/netscape/cmscore/request/RequestModDefaultStub.java
similarity index 100%
rename from base/common/test/com/netscape/cmscore/request/RequestModDefaultStub.java
rename to base/server/test/com/netscape/cmscore/request/RequestModDefaultStub.java
diff --git a/base/common/test/com/netscape/cmscore/request/RequestQueueTest.java b/base/server/test/com/netscape/cmscore/request/RequestQueueTest.java
similarity index 100%
rename from base/common/test/com/netscape/cmscore/request/RequestQueueTest.java
rename to base/server/test/com/netscape/cmscore/request/RequestQueueTest.java
diff --git a/base/common/test/com/netscape/cmscore/request/RequestRecordTest.java b/base/server/test/com/netscape/cmscore/request/RequestRecordTest.java
similarity index 100%
rename from base/common/test/com/netscape/cmscore/request/RequestRecordTest.java
rename to base/server/test/com/netscape/cmscore/request/RequestRecordTest.java
diff --git a/base/common/test/com/netscape/cmscore/request/RequestTest.java b/base/server/test/com/netscape/cmscore/request/RequestTest.java
similarity index 99%
rename from base/common/test/com/netscape/cmscore/request/RequestTest.java
rename to base/server/test/com/netscape/cmscore/request/RequestTest.java
index 4f761f982c7aa36fd9528de6cc8001c4805251f7..11070264b151e6e2686ad011cfa4a078639645d2 100644
--- a/base/common/test/com/netscape/cmscore/request/RequestTest.java
+++ b/base/server/test/com/netscape/cmscore/request/RequestTest.java
@@ -18,12 +18,12 @@ import netscape.security.x509.X500Name;
 import netscape.security.x509.X509CertImpl;
 import netscape.security.x509.X509CertInfo;
 
-import com.netscape.certsrv.app.CMSEngineDefaultStub;
 import com.netscape.certsrv.apps.CMS;
 import com.netscape.certsrv.authentication.AuthToken;
 import com.netscape.certsrv.authentication.IAuthToken;
 import com.netscape.certsrv.base.EBaseException;
 import com.netscape.certsrv.request.RequestId;
+import com.netscape.cmscore.app.CMSEngineDefaultStub;
 import com.netscape.cmscore.test.CMSBaseTestCase;
 import com.netscape.cmscore.test.TestHelper;
 
diff --git a/base/common/test/com/netscape/cmscore/test/CMSBaseTestCase.java b/base/server/test/com/netscape/cmscore/test/CMSBaseTestCase.java
similarity index 97%
rename from base/common/test/com/netscape/cmscore/test/CMSBaseTestCase.java
rename to base/server/test/com/netscape/cmscore/test/CMSBaseTestCase.java
index 007ccafcb07b25f4808af633c4434f4dc0d3c6a0..045dda11ed2005b1af07a2a9b1044beeed69d7bb 100644
--- a/base/common/test/com/netscape/cmscore/test/CMSBaseTestCase.java
+++ b/base/server/test/com/netscape/cmscore/test/CMSBaseTestCase.java
@@ -5,16 +5,16 @@ import java.security.cert.CertificateException;
 import junit.framework.TestCase;
 import netscape.security.x509.X509CertImpl;
 
-import com.netscape.certsrv.app.CMSEngineDefaultStub;
 import com.netscape.certsrv.apps.CMS;
 import com.netscape.certsrv.dbs.IDBRegistry;
 import com.netscape.certsrv.dbs.IDBSSession;
 import com.netscape.certsrv.logging.ILogger;
-import com.netscape.certsrv.logging.LoggerDefaultStub;
+import com.netscape.cmscore.app.CMSEngineDefaultStub;
 import com.netscape.cmscore.dbs.DBRegistryDefaultStub;
 import com.netscape.cmscore.dbs.DBSSessionDefaultStub;
 import com.netscape.cmscore.dbs.DBSubsystem;
 import com.netscape.cmscore.dbs.DBSubsystemDefaultStub;
+import com.netscape.cmscore.logging.LoggerDefaultStub;
 
 /**
  * The base class for all CMS unit tests. This sets up some basic stubs
diff --git a/base/common/test/com/netscape/cmscore/test/TestHelper.java b/base/server/test/com/netscape/cmscore/test/TestHelper.java
similarity index 100%
rename from base/common/test/com/netscape/cmscore/test/TestHelper.java
rename to base/server/test/com/netscape/cmscore/test/TestHelper.java
-- 
1.8.1.4

