mirror of https://github.com/OpenIdentityPlatform/OpenDJ.git

gbellato
25.35.2007 5349c97806bb0a00038d8dc3dee4254fad187649
opends/tests/unit-tests-testng/src/server/org/opends/server/replication/ReplicationTestCase.java
File was renamed from opends/tests/unit-tests-testng/src/server/org/opends/server/replication/SynchronizationTestCase.java
@@ -65,10 +65,10 @@
import org.testng.annotations.BeforeClass;
/**
 * An abstract class that all synchronization unit test should extend.
 * An abstract class that all Replication unit test should extend.
 */
@Test(groups = { "precommit", "synchronization" })
public abstract class SynchronizationTestCase extends DirectoryServerTestCase
@Test(groups = { "precommit", "replication" })
public abstract class ReplicationTestCase extends DirectoryServerTestCase
{
  /**
@@ -92,7 +92,7 @@
  protected boolean schemaCheck;
  /**
   * The synchronization plugin entry
   * The replication plugin entry
   */
  protected String synchroPluginStringDN =
    "cn=Multimaster Synchronization, cn=Synchronization Providers,cn=config";
@@ -155,7 +155,7 @@
      { 
        logError(ErrorLogCategory.SYNCHRONIZATION,
            ErrorLogSeverity.NOTICE,
            "SynchronizationTestCase/openChangelogSession" + e.getMessage(), 1);
            "ReplicationTestCase/openChangelogSession" + e.getMessage(), 1);
      }
    }
    return broker;
@@ -231,7 +231,7 @@
  {
    logError(ErrorLogCategory.SYNCHRONIZATION,
        ErrorLogSeverity.NOTICE,
        "SynchronizationTestCase/Cleaning config entries" , 1);
        "ReplicationTestCase/Cleaning config entries" , 1);
    DeleteOperation op;
    // Delete entries
@@ -263,7 +263,7 @@
  {
   logError(ErrorLogCategory.SYNCHRONIZATION,
        ErrorLogSeverity.NOTICE,
        "SynchronizationTestCase/Cleaning entries" , 1);
        "ReplicationTestCase/Cleaning entries" , 1);
  
    DeleteOperation op;
    // Delete entries
@@ -304,24 +304,24 @@
  }
  /**
   * Configure the Synchronization for this test.
   * Configure the replication for this test.
   */
  protected void configureSynchronization() throws Exception
  protected void configureReplication() throws Exception
  {
    // Add the Multimaster synchronization plugin
    // Add the Multimaster replication plugin
    String synchroPluginLdif = "dn: " + synchroPluginStringDN + "\n"
         + "objectClass: top\n"
         + "objectClass: ds-cfg-synchronization-provider\n"
         + "objectClass: ds-cfg-multimaster-synchronization-provider\n"
         + "ds-cfg-synchronization-provider-enabled: true\n"
         + "ds-cfg-synchronization-provider-class: " +
         "org.opends.server.replication.plugin.MultimasterSynchronization\n";
         "org.opends.server.replication.plugin.MultimasterReplication\n";
    Entry synchroPluginEntry = TestCaseUtils.entryFromLdifString(synchroPluginLdif);
    DirectoryServer.getConfigHandler().addEntry(synchroPluginEntry, null);
    configEntryList.add(synchroPluginEntry.getDN());
    assertNotNull(DirectoryServer.getConfigEntry(DN
        .decode(synchroPluginStringDN)),
        "Unable to add the Multimaster synchronization plugin");
        "Unable to add the Multimaster replication plugin");
    
    // domains container entry.
    String domainsLdif = "dn: "
@@ -333,7 +333,7 @@
    configEntryList.add(domainsEntry.getDN());
    assertNotNull(DirectoryServer.getConfigEntry(
      DN.decode(synchroPluginStringDN)),
      "Unable to add the Multimaster synchronization plugin");
      "Unable to add the Multimaster replication plugin");
      
    // Add the changelog server
@@ -342,7 +342,7 @@
       "Unable to add the changeLog server");
    configEntryList.add(changeLogEntry.getDN());
    // We also have a replicated suffix (synchronization domain)
    // We also have a replicated suffix (replication domain)
    DirectoryServer.getConfigHandler().addEntry(synchroServerEntry, null);
    assertNotNull(DirectoryServer.getConfigEntry(synchroServerEntry.getDN()),
        "Unable to add the synchronized server");
@@ -350,7 +350,7 @@
  }
  /**
   * Retrieve the number of replayed updates for a given synchronization
   * Retrieve the number of replayed updates for a given replication
   * domain from the monitor entry.
   * @return The number of replayed updates.
   * @throws Exception If an error occurs.