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

gbellato
08.45.2007 7302736c0007f2851e1b8bce3101e18ec884090f
opends/tests/unit-tests-testng/src/server/org/opends/server/replication/InitOnLineTest.java
@@ -1453,8 +1453,27 @@
  protected void afterTest()
  {
    // Check that the domain hsa completed the import/export task.
    if (replDomain != null)
    {
      // race condition could cause the main thread to reach
      // this code before the task is fully completed.
      // in those cases, loop for a while waiting for completion.
      for (int i = 0; i< 10; i++)
      {
        if (replDomain.ieRunning())
        {
          try
          {
            Thread.sleep(500);
          } catch (InterruptedException e)
          { }
        }
        else
        {
          break;
        }
      }
       assertTrue(!replDomain.ieRunning(),
         "ReplicationDomain: Import/Export is not expected to be running");
    }