directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kayyag...@apache.org
Subject svn commit: r929315 - in /directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api: ./ operations/ operations/bind/ operations/search/ perf/
Date Tue, 30 Mar 2010 21:50:02 GMT
Author: kayyagari
Date: Tue Mar 30 21:50:01 2010
New Revision: 929315

URL: http://svn.apache.org/viewvc?rev=929315&view=rev
Log:
o updated according to the changes done to LdapConnection class
o fixed some ignored tests in LdapConnectionTest

Modified:
    directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/LdapConnectionTest.java
    directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/LdapSSLConnectionTest.java
    directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/ClientAbandonRequestTest.java
    directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/ClientAddRequestTest.java
    directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/ClientCompareRequestTest.java
    directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/ClientDeleteRequestTest.java
    directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/ClientExtendedRequestTest.java
    directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/ClientModifyDnRequestTest.java
    directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/ClientModifyRequestTest.java
    directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/bind/SimpleBindRequestTest.java
    directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/search/ClientSearchRequestTest.java
    directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/search/SearchRequestReturningAttributesTest.java
    directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/perf/TestClientApiPerf.java

Modified: directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/LdapConnectionTest.java
URL: http://svn.apache.org/viewvc/directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/LdapConnectionTest.java?rev=929315&r1=929314&r2=929315&view=diff
==============================================================================
--- directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/LdapConnectionTest.java
(original)
+++ directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/LdapConnectionTest.java
Tue Mar 30 21:50:01 2010
@@ -27,9 +27,9 @@ import static org.junit.Assert.assertTru
 import static org.junit.Assert.fail;
 
 import java.io.IOException;
-import java.util.Arrays;
 import java.util.List;
 
+import org.apache.directory.ldap.client.api.LdapNetworkConnection;
 import org.apache.directory.ldap.client.api.LdapConnection;
 import org.apache.directory.ldap.client.api.exception.LdapException;
 import org.apache.directory.ldap.client.api.message.BindResponse;
@@ -48,7 +48,6 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.schema.SchemaManager;
 import org.junit.After;
 import org.junit.Before;
-import org.junit.Ignore;
 import org.junit.Test;
 import org.junit.runner.RunWith;
 
@@ -76,7 +75,7 @@ public class LdapConnectionTest extends 
     @Before
     public void bindConnection() throws Exception
     {
-        connection = new LdapConnection( "localhost", ldapServer.getPort() );
+        connection = new LdapNetworkConnection( "localhost", ldapServer.getPort() );
         connection.bind( ADMIN_DN, "secret" );
     }
     
@@ -96,7 +95,7 @@ public class LdapConnectionTest extends 
     @Test
     public void testBindRequest() throws Exception
     {
-        LdapConnection connection = new LdapConnection( "localhost", ldapServer.getPort()
);
+        LdapConnection connection = new LdapNetworkConnection( "localhost", ldapServer.getPort()
);
         try
         {
             BindResponse bindResponse = connection.bind( ADMIN_DN, "secret" );
@@ -152,7 +151,6 @@ public class LdapConnectionTest extends 
     }
     
 
-    @Ignore( "failing to lookup an existing entry based on the entryUUID AT" )
     @Test
     public void searchByEntryUuid() throws Exception
     {
@@ -173,13 +171,16 @@ public class LdapConnectionTest extends 
     }
 
     
-    @Ignore( "failing to treat the userPassword AT as a binary attribute" )
     @Test
     public void testRetrieveBinaryAttibute() throws Exception
     {
         Entry entry = ( ( SearchResultEntry ) connection.lookup( "uid=admin,ou=system" )
).getEntry();
+        assertFalse( entry.get( SchemaConstants.USER_PASSWORD_AT ).get().isBinary() );
+
+        connection.loadSchema();
         
-        assertTrue( Arrays.equals( "secret".getBytes(), entry.get( SchemaConstants.USER_PASSWORD_AT
).getBytes() ) );
+        entry = ( ( SearchResultEntry ) connection.lookup( "uid=admin,ou=system" ) ).getEntry();
+        assertTrue( entry.get( SchemaConstants.USER_PASSWORD_AT ).get().isBinary() );
     }
 
     
@@ -191,4 +192,5 @@ public class LdapConnectionTest extends 
         assertNotNull( manager );
         assertTrue( manager.isEnabled( "system" ) );
     }
+    
 }

Modified: directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/LdapSSLConnectionTest.java
URL: http://svn.apache.org/viewvc/directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/LdapSSLConnectionTest.java?rev=929315&r1=929314&r2=929315&view=diff
==============================================================================
--- directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/LdapSSLConnectionTest.java
(original)
+++ directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/LdapSSLConnectionTest.java
Tue Mar 30 21:50:01 2010
@@ -31,6 +31,7 @@ import java.util.List;
 import javax.net.ssl.TrustManager;
 import javax.net.ssl.X509TrustManager;
 
+import org.apache.directory.ldap.client.api.LdapNetworkConnection;
 import org.apache.directory.ldap.client.api.LdapConnection;
 import org.apache.directory.ldap.client.api.LdapConnectionConfig;
 import org.apache.directory.ldap.client.api.message.BindResponse;
@@ -121,7 +122,7 @@ public class LdapSSLConnectionTest exten
         LdapConnection connection = null;
         try
         {
-            connection = new LdapConnection( config );
+            connection = new LdapNetworkConnection( config );
             BindResponse bindResponse = connection.bind( "uid=admin,ou=system", "secret"
);
             
             assertNotNull( bindResponse );
@@ -139,7 +140,7 @@ public class LdapSSLConnectionTest exten
     @Test
     public void testGetSupportedControls() throws Exception
     {
-        LdapConnection connection = new LdapConnection( config );
+        LdapConnection connection = new LdapNetworkConnection( config );
 
         DN dn = new DN( "uid=admin,ou=system" );
         connection.bind( dn.getName(), "secret" );

Modified: directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/ClientAbandonRequestTest.java
URL: http://svn.apache.org/viewvc/directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/ClientAbandonRequestTest.java?rev=929315&r1=929314&r2=929315&view=diff
==============================================================================
--- directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/ClientAbandonRequestTest.java
(original)
+++ directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/ClientAbandonRequestTest.java
Tue Mar 30 21:50:01 2010
@@ -25,7 +25,8 @@ import static org.junit.Assert.assertEqu
 import static org.junit.Assert.assertTrue;
 import static org.junit.Assert.fail;
 
-import org.apache.directory.ldap.client.api.LdapConnection;
+import org.apache.directory.ldap.client.api.LdapAsyncConnection;
+import org.apache.directory.ldap.client.api.LdapNetworkConnection;
 import org.apache.directory.ldap.client.api.future.SearchFuture;
 import org.apache.directory.ldap.client.api.message.SearchRequest;
 import org.apache.directory.ldap.client.api.message.SearchResponse;
@@ -64,14 +65,14 @@ import org.junit.runner.RunWith;
 public class ClientAbandonRequestTest extends AbstractLdapTestUnit
 {
 
-    private LdapConnection connection;
+    private LdapAsyncConnection connection;
 
     private CoreSession session;
     
     @Before
     public void setup() throws Exception
     {
-        connection = new LdapConnection( "localhost", ldapServer.getPort() );
+        connection = new LdapNetworkConnection( "localhost", ldapServer.getPort() );
         DN bindDn = new DN( "uid=admin,ou=system" );
         connection.setTimeOut( 0L );
         connection.bind( bindDn.getName(), "secret" );

Modified: directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/ClientAddRequestTest.java
URL: http://svn.apache.org/viewvc/directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/ClientAddRequestTest.java?rev=929315&r1=929314&r2=929315&view=diff
==============================================================================
--- directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/ClientAddRequestTest.java
(original)
+++ directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/ClientAddRequestTest.java
Tue Mar 30 21:50:01 2010
@@ -29,7 +29,8 @@ import static org.junit.Assert.fail;
 import java.util.concurrent.TimeUnit;
 import java.util.concurrent.TimeoutException;
 
-import org.apache.directory.ldap.client.api.LdapConnection;
+import org.apache.directory.ldap.client.api.LdapAsyncConnection;
+import org.apache.directory.ldap.client.api.LdapNetworkConnection;
 import org.apache.directory.ldap.client.api.future.AddFuture;
 import org.apache.directory.ldap.client.api.message.AddRequest;
 import org.apache.directory.ldap.client.api.message.AddResponse;
@@ -63,13 +64,13 @@ import org.junit.runner.RunWith;
     })
 public class ClientAddRequestTest extends AbstractLdapTestUnit
 {
-    private LdapConnection connection;
+    private LdapAsyncConnection connection;
     private CoreSession session;
     
     @Before
     public void setup() throws Exception
     {
-        connection = new LdapConnection( "localhost", ldapServer.getPort() );
+        connection = new LdapNetworkConnection( "localhost", ldapServer.getPort() );
         DN bindDn = new DN( "uid=admin,ou=system" );
         connection.bind( bindDn.getName(), "secret" );
         

Modified: directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/ClientCompareRequestTest.java
URL: http://svn.apache.org/viewvc/directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/ClientCompareRequestTest.java?rev=929315&r1=929314&r2=929315&view=diff
==============================================================================
--- directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/ClientCompareRequestTest.java
(original)
+++ directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/ClientCompareRequestTest.java
Tue Mar 30 21:50:01 2010
@@ -28,7 +28,8 @@ import static org.junit.Assert.fail;
 import java.util.concurrent.TimeUnit;
 import java.util.concurrent.TimeoutException;
 
-import org.apache.directory.ldap.client.api.LdapConnection;
+import org.apache.directory.ldap.client.api.LdapAsyncConnection;
+import org.apache.directory.ldap.client.api.LdapNetworkConnection;
 import org.apache.directory.ldap.client.api.future.CompareFuture;
 import org.apache.directory.ldap.client.api.message.CompareRequest;
 import org.apache.directory.ldap.client.api.message.CompareResponse;
@@ -60,14 +61,14 @@ import org.junit.runner.RunWith;
     })
 public class ClientCompareRequestTest extends AbstractLdapTestUnit
 {
-    private LdapConnection connection;
+    private LdapAsyncConnection connection;
     
     private CoreSession session;
     
     @Before
     public void setup() throws Exception
     {
-        connection = new LdapConnection( "localhost", ldapServer.getPort() );
+        connection = new LdapNetworkConnection( "localhost", ldapServer.getPort() );
         DN bindDn = new DN( "uid=admin,ou=system" );
         connection.bind( bindDn.getName(), "secret" );
         

Modified: directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/ClientDeleteRequestTest.java
URL: http://svn.apache.org/viewvc/directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/ClientDeleteRequestTest.java?rev=929315&r1=929314&r2=929315&view=diff
==============================================================================
--- directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/ClientDeleteRequestTest.java
(original)
+++ directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/ClientDeleteRequestTest.java
Tue Mar 30 21:50:01 2010
@@ -32,7 +32,8 @@ import java.util.concurrent.TimeUnit;
 import java.util.concurrent.TimeoutException;
 import java.util.concurrent.atomic.AtomicInteger;
 
-import org.apache.directory.ldap.client.api.LdapConnection;
+import org.apache.directory.ldap.client.api.LdapAsyncConnection;
+import org.apache.directory.ldap.client.api.LdapNetworkConnection;
 import org.apache.directory.ldap.client.api.exception.LdapException;
 import org.apache.directory.ldap.client.api.future.DeleteFuture;
 import org.apache.directory.ldap.client.api.listener.DeleteListener;
@@ -101,7 +102,7 @@ import org.junit.runner.RunWith;
 })
 public class ClientDeleteRequestTest extends AbstractLdapTestUnit
 {
-    private LdapConnection connection;
+    private LdapNetworkConnection connection;
     
     private CoreSession session;
     
@@ -109,7 +110,7 @@ public class ClientDeleteRequestTest ext
     @Before
     public void setup() throws Exception
     {
-        connection = new LdapConnection( "localhost", ldapServer.getPort() );
+        connection = new LdapNetworkConnection( "localhost", ldapServer.getPort() );
 
         DN bindDn = new DN( "uid=admin,ou=system" );
         connection.bind( bindDn.getName(), "secret" );
@@ -234,7 +235,7 @@ public class ClientDeleteRequestTest ext
         
         DeleteListener listener = new DeleteListener()
         {
-            public void entryDeleted( LdapConnection connection, DeleteResponse response
) throws LdapException
+            public void entryDeleted( LdapAsyncConnection connection, DeleteResponse response
) throws LdapException
             {
                 assertNotNull( response );
                 assertEquals( ResultCodeEnum.SUCCESS, response.getLdapResult().getResultCode()
);

Modified: directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/ClientExtendedRequestTest.java
URL: http://svn.apache.org/viewvc/directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/ClientExtendedRequestTest.java?rev=929315&r1=929314&r2=929315&view=diff
==============================================================================
--- directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/ClientExtendedRequestTest.java
(original)
+++ directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/ClientExtendedRequestTest.java
Tue Mar 30 21:50:01 2010
@@ -30,7 +30,8 @@ import java.util.concurrent.TimeoutExcep
 
 import javax.naming.ldap.StartTlsRequest;
 
-import org.apache.directory.ldap.client.api.LdapConnection;
+import org.apache.directory.ldap.client.api.LdapAsyncConnection;
+import org.apache.directory.ldap.client.api.LdapNetworkConnection;
 import org.apache.directory.ldap.client.api.future.ExtendedFuture;
 import org.apache.directory.ldap.client.api.message.ExtendedRequest;
 import org.apache.directory.ldap.client.api.message.ExtendedResponse;
@@ -66,13 +67,13 @@ import org.junit.runner.RunWith;
    })
 public class ClientExtendedRequestTest extends AbstractLdapTestUnit
 {
-   private LdapConnection connection;
+   private LdapAsyncConnection connection;
    private CoreSession session;
 
    @Before
    public void setup() throws Exception
    {
-       connection = new LdapConnection( "localhost", ldapServer.getPort() );
+       connection = new LdapNetworkConnection( "localhost", ldapServer.getPort() );
        DN bindDn = new DN( "uid=admin,ou=system" );
        connection.bind( bindDn.getName(), "secret" );
 

Modified: directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/ClientModifyDnRequestTest.java
URL: http://svn.apache.org/viewvc/directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/ClientModifyDnRequestTest.java?rev=929315&r1=929314&r2=929315&view=diff
==============================================================================
--- directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/ClientModifyDnRequestTest.java
(original)
+++ directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/ClientModifyDnRequestTest.java
Tue Mar 30 21:50:01 2010
@@ -28,7 +28,8 @@ import static org.junit.Assert.fail;
 import java.util.concurrent.TimeUnit;
 import java.util.concurrent.TimeoutException;
 
-import org.apache.directory.ldap.client.api.LdapConnection;
+import org.apache.directory.ldap.client.api.LdapAsyncConnection;
+import org.apache.directory.ldap.client.api.LdapNetworkConnection;
 import org.apache.directory.ldap.client.api.future.ModifyDnFuture;
 import org.apache.directory.ldap.client.api.message.ModifyDnRequest;
 import org.apache.directory.ldap.client.api.message.ModifyDnResponse;
@@ -67,7 +68,7 @@ import org.junit.runner.RunWith;
     })
 public class ClientModifyDnRequestTest extends AbstractLdapTestUnit
 {
-    private LdapConnection connection;
+    private LdapAsyncConnection connection;
     
     private CoreSession session;
     
@@ -76,7 +77,7 @@ public class ClientModifyDnRequestTest e
     @Before
     public void setup() throws Exception
     {
-        connection = new LdapConnection( "localhost", ldapServer.getPort() );
+        connection = new LdapNetworkConnection( "localhost", ldapServer.getPort() );
 
         DN bindDn = new DN( "uid=admin,ou=system" );
         connection.bind( bindDn.getName(), "secret" );

Modified: directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/ClientModifyRequestTest.java
URL: http://svn.apache.org/viewvc/directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/ClientModifyRequestTest.java?rev=929315&r1=929314&r2=929315&view=diff
==============================================================================
--- directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/ClientModifyRequestTest.java
(original)
+++ directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/ClientModifyRequestTest.java
Tue Mar 30 21:50:01 2010
@@ -28,7 +28,8 @@ import static org.junit.Assert.fail;
 import java.util.concurrent.TimeUnit;
 import java.util.concurrent.TimeoutException;
 
-import org.apache.directory.ldap.client.api.LdapConnection;
+import org.apache.directory.ldap.client.api.LdapAsyncConnection;
+import org.apache.directory.ldap.client.api.LdapNetworkConnection;
 import org.apache.directory.ldap.client.api.future.ModifyFuture;
 import org.apache.directory.ldap.client.api.message.ModifyRequest;
 import org.apache.directory.ldap.client.api.message.ModifyResponse;
@@ -64,14 +65,14 @@ import org.junit.runner.RunWith;
     })
 public class ClientModifyRequestTest extends AbstractLdapTestUnit
 {
-    private LdapConnection connection;
+    private LdapAsyncConnection connection;
     
     private CoreSession session;
     
     @Before
     public void setup() throws Exception
     {
-        connection = new LdapConnection( "localhost", ldapServer.getPort() );
+        connection = new LdapNetworkConnection( "localhost", ldapServer.getPort() );
 
         DN bindDn = new DN( "uid=admin,ou=system" );
         connection.bind( bindDn.getName(), "secret" );

Modified: directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/bind/SimpleBindRequestTest.java
URL: http://svn.apache.org/viewvc/directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/bind/SimpleBindRequestTest.java?rev=929315&r1=929314&r2=929315&view=diff
==============================================================================
--- directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/bind/SimpleBindRequestTest.java
(original)
+++ directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/bind/SimpleBindRequestTest.java
Tue Mar 30 21:50:01 2010
@@ -28,7 +28,9 @@ import static org.junit.Assert.fail;
 import java.util.concurrent.TimeUnit;
 import java.util.concurrent.TimeoutException;
 
+import org.apache.directory.ldap.client.api.LdapAsyncConnection;
 import org.apache.directory.ldap.client.api.LdapConnection;
+import org.apache.directory.ldap.client.api.LdapNetworkConnection;
 import org.apache.directory.ldap.client.api.future.BindFuture;
 import org.apache.directory.ldap.client.api.message.BindRequest;
 import org.apache.directory.ldap.client.api.message.BindResponse;
@@ -75,7 +77,7 @@ import org.junit.runner.RunWith;
 })
 public class SimpleBindRequestTest extends AbstractLdapTestUnit
 {
-    private LdapConnection connection;
+    private LdapAsyncConnection connection;
 
     
     /**
@@ -84,7 +86,7 @@ public class SimpleBindRequestTest exten
     @Before
     public void setup() throws Exception
     {
-        connection = new LdapConnection( "localhost", ldapServer.getPort() );
+        connection = new LdapNetworkConnection( "localhost", ldapServer.getPort() );
     }
 
     
@@ -166,7 +168,7 @@ public class SimpleBindRequestTest exten
         for ( int i = 0; i < 5; i++)
         {
             //System.out.println( "------------------Create connection" + i + "-------------"
);
-            LdapConnection connection = new LdapConnection( "localhost", ldapServer.getPort()
);
+            LdapConnection connection = new LdapNetworkConnection( "localhost", ldapServer.getPort()
);
             //System.out.println( "------------------Bind" + i + "-------------" );
             
             // Try with no parameters
@@ -183,7 +185,7 @@ public class SimpleBindRequestTest exten
             assertFalse( connection.isConnected() );
     
             // Try with empty strings
-            connection = new LdapConnection( "localhost", ldapServer.getPort() );
+            connection = new LdapNetworkConnection( "localhost", ldapServer.getPort() );
             bindResponse = connection.bind( "", "" );
             
             assertNotNull( bindResponse );
@@ -196,7 +198,7 @@ public class SimpleBindRequestTest exten
             assertFalse( connection.isConnected() );
     
             // Try with null parameters
-            connection = new LdapConnection( "localhost", ldapServer.getPort() );
+            connection = new LdapNetworkConnection( "localhost", ldapServer.getPort() );
             bindResponse = connection.bind( (String)null, (String)null );
             
             assertNotNull( bindResponse );
@@ -209,7 +211,7 @@ public class SimpleBindRequestTest exten
             connection.unBind();
             assertFalse( connection.isConnected() );
 
-            connection = new LdapConnection( "localhost", ldapServer.getPort() );
+            connection = new LdapNetworkConnection( "localhost", ldapServer.getPort() );
             
             
             //System.out.println( "----------------Unbind done" + i + "-------------" );

Modified: directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/search/ClientSearchRequestTest.java
URL: http://svn.apache.org/viewvc/directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/search/ClientSearchRequestTest.java?rev=929315&r1=929314&r2=929315&view=diff
==============================================================================
--- directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/search/ClientSearchRequestTest.java
(original)
+++ directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/search/ClientSearchRequestTest.java
Tue Mar 30 21:50:01 2010
@@ -27,7 +27,8 @@ import static org.junit.Assert.fail;
 
 import java.util.concurrent.TimeUnit;
 
-import org.apache.directory.ldap.client.api.LdapConnection;
+import org.apache.directory.ldap.client.api.LdapAsyncConnection;
+import org.apache.directory.ldap.client.api.LdapNetworkConnection;
 import org.apache.directory.ldap.client.api.future.SearchFuture;
 import org.apache.directory.ldap.client.api.message.SearchRequest;
 import org.apache.directory.ldap.client.api.message.SearchResponse;
@@ -79,12 +80,12 @@ import org.junit.runner.RunWith;
 })
 public class ClientSearchRequestTest extends AbstractLdapTestUnit
 {
-    private LdapConnection connection;
+    private LdapAsyncConnection connection;
 
     @Before
     public void setup() throws Exception
     {
-        connection = new LdapConnection( "localhost", ldapServer.getPort() );
+        connection = new LdapNetworkConnection( "localhost", ldapServer.getPort() );
         DN bindDn = new DN( "uid=admin,ou=system" );
         connection.bind( bindDn.getName(), "secret" );
     }

Modified: directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/search/SearchRequestReturningAttributesTest.java
URL: http://svn.apache.org/viewvc/directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/search/SearchRequestReturningAttributesTest.java?rev=929315&r1=929314&r2=929315&view=diff
==============================================================================
--- directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/search/SearchRequestReturningAttributesTest.java
(original)
+++ directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/search/SearchRequestReturningAttributesTest.java
Tue Mar 30 21:50:01 2010
@@ -26,6 +26,7 @@ import static org.junit.Assert.assertNot
 import static org.junit.Assert.assertTrue;
 import static org.junit.Assert.fail;
 
+import org.apache.directory.ldap.client.api.LdapNetworkConnection;
 import org.apache.directory.ldap.client.api.LdapConnection;
 import org.apache.directory.ldap.client.api.message.SearchResponse;
 import org.apache.directory.ldap.client.api.message.SearchResultEntry;
@@ -79,7 +80,7 @@ public class SearchRequestReturningAttri
     @Before
     public void setup() throws Exception
     {
-        connection = new LdapConnection( "localhost", ldapServer.getPort() );
+        connection = new LdapNetworkConnection( "localhost", ldapServer.getPort() );
         DN bindDn = new DN( "uid=admin,ou=system" );
         connection.bind( bindDn.getName(), "secret" );
     }

Modified: directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/perf/TestClientApiPerf.java
URL: http://svn.apache.org/viewvc/directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/perf/TestClientApiPerf.java?rev=929315&r1=929314&r2=929315&view=diff
==============================================================================
--- directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/perf/TestClientApiPerf.java
(original)
+++ directory/clients/ldap/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/perf/TestClientApiPerf.java
Tue Mar 30 21:50:01 2010
@@ -30,6 +30,7 @@ import javax.naming.directory.InitialDir
 import javax.naming.directory.SearchControls;
 import javax.naming.directory.SearchResult;
 
+import org.apache.directory.ldap.client.api.LdapNetworkConnection;
 import org.apache.directory.ldap.client.api.LdapConnection;
 import org.apache.directory.ldap.client.api.message.SearchResponse;
 import org.apache.directory.ldap.client.api.message.SearchResultEntry;
@@ -92,7 +93,7 @@ public class TestClientApiPerf extends A
         long t1 = System.currentTimeMillis();
 
         // Create connection
-        LdapConnection connection = new LdapConnection( "localhost", ldapServer.getPort()
);
+        LdapConnection connection = new LdapNetworkConnection( "localhost", ldapServer.getPort()
);
         connection.bind( "uid=admin,ou=system", "secret" );
 
         long t2 = System.currentTimeMillis();



Mime
View raw message