directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From elecha...@apache.org
Subject svn commit: r894815 - in /directory/apacheds/branches/apacheds-schema/test-framework/src/main/java/org/apache/directory/server/core/integ: FrameworkRunner.java FrameworkSuite.java
Date Thu, 31 Dec 2009 11:11:59 GMT
Author: elecharny
Date: Thu Dec 31 11:11:58 2009
New Revision: 894815

URL: http://svn.apache.org/viewvc?rev=894815&view=rev
Log:
Fixed the port error

Modified:
    directory/apacheds/branches/apacheds-schema/test-framework/src/main/java/org/apache/directory/server/core/integ/FrameworkRunner.java
    directory/apacheds/branches/apacheds-schema/test-framework/src/main/java/org/apache/directory/server/core/integ/FrameworkSuite.java

Modified: directory/apacheds/branches/apacheds-schema/test-framework/src/main/java/org/apache/directory/server/core/integ/FrameworkRunner.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/apacheds-schema/test-framework/src/main/java/org/apache/directory/server/core/integ/FrameworkRunner.java?rev=894815&r1=894814&r2=894815&view=diff
==============================================================================
--- directory/apacheds/branches/apacheds-schema/test-framework/src/main/java/org/apache/directory/server/core/integ/FrameworkRunner.java
(original)
+++ directory/apacheds/branches/apacheds-schema/test-framework/src/main/java/org/apache/directory/server/core/integ/FrameworkRunner.java
Thu Dec 31 11:11:58 2009
@@ -30,6 +30,7 @@
 import org.apache.directory.server.core.factory.DirectoryServiceFactory;
 import org.apache.directory.server.factory.ServerAnnotationProcessor;
 import org.apache.directory.server.ldap.LdapServer;
+import org.apache.directory.server.protocol.shared.transport.Transport;
 import org.junit.Ignore;
 import org.junit.runner.Description;
 import org.junit.runner.notification.RunNotifier;
@@ -111,8 +112,22 @@
                 LOG.debug( "Create revision {}", revision );
 
                 DSAnnotationProcessor.applyLdifs( getDescription(), classDS );
+                int minPort = 0;
                 
-                classLdapServer = ServerAnnotationProcessor.getLdapServer( getDescription(),
classDS );
+                if ( suite != null )
+                {
+                    LdapServer suiteServer = suite.getLdapServer();
+                    
+                    for ( Transport transport : suiteServer.getTransports() )
+                    {
+                        if ( minPort <= transport.getPort() )
+                        {
+                            minPort = transport.getPort();
+                        }
+                    }
+                }
+                
+                classLdapServer = ServerAnnotationProcessor.getLdapServer( getDescription(),
classDS, minPort + 1 );
             }
             else if( suite != null && suite.getLdapServer() != null )
             {

Modified: directory/apacheds/branches/apacheds-schema/test-framework/src/main/java/org/apache/directory/server/core/integ/FrameworkSuite.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/apacheds-schema/test-framework/src/main/java/org/apache/directory/server/core/integ/FrameworkSuite.java?rev=894815&r1=894814&r2=894815&view=diff
==============================================================================
--- directory/apacheds/branches/apacheds-schema/test-framework/src/main/java/org/apache/directory/server/core/integ/FrameworkSuite.java
(original)
+++ directory/apacheds/branches/apacheds-schema/test-framework/src/main/java/org/apache/directory/server/core/integ/FrameworkSuite.java
Thu Dec 31 11:11:58 2009
@@ -125,7 +125,7 @@
     {
         try
         {
-            ldapServer = ServerAnnotationProcessor.getLdapServer( description, directoryService
);
+            ldapServer = ServerAnnotationProcessor.getLdapServer( description, directoryService,
1024 );
         }
         catch ( Exception e )
         {



Mime
View raw message