From 585d1bf2936de4197aaf3af84f07a5607e013a1e Mon Sep 17 00:00:00 2001
From: Jean-Noel Rouvignac <jean-noel.rouvignac@forgerock.com>
Date: Fri, 09 Aug 2013 08:34:00 +0000
Subject: [PATCH] *Test*.java: Used TestCaseUtils.findFreePort() instead of TestCaseUtils.bindFreePort(). Used StaticUtils.close().
---
opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/HistoricalTest.java | 8 +-------
1 files changed, 1 insertions(+), 7 deletions(-)
diff --git a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/HistoricalTest.java b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/HistoricalTest.java
index 9c39663..d7d60cb 100644
--- a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/HistoricalTest.java
+++ b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/HistoricalTest.java
@@ -25,10 +25,8 @@
* Copyright 2008-2010 Sun Microsystems, Inc.
* Portions Copyright 2011-2013 ForgeRock AS
*/
-
package org.opends.server.replication.plugin;
-
import static org.opends.server.TestCaseUtils.*;
import static org.testng.Assert.*;
@@ -48,7 +46,6 @@
import org.testng.annotations.BeforeClass;
import org.testng.annotations.Test;
-import java.net.ServerSocket;
import java.util.ArrayList;
import java.util.LinkedList;
import java.util.List;
@@ -76,10 +73,7 @@
// Create an internal connection.
connection = InternalClientConnection.getRootConnection();
- // find a free port for the replicationServer
- ServerSocket socket = TestCaseUtils.bindFreePort();
- replServerPort = socket.getLocalPort();
- socket.close();
+ replServerPort = TestCaseUtils.findFreePort();
// The replication server.
String replServerStringDN = "cn=Replication Server, " + SYNCHRO_PLUGIN_DN;
--
Gitblit v1.10.0