directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From trus...@apache.org
Subject svn commit: r165104 - /directory/network/trunk/src/test/org/apache/mina/examples/echoserver/ConnectorTest.java
Date Thu, 28 Apr 2005 06:10:21 GMT
Author: trustin
Date: Wed Apr 27 23:10:20 2005
New Revision: 165104

URL: http://svn.apache.org/viewcvs?rev=165104&view=rev
Log:
Fixed: ConnectorTest cometimes fails while coverage testing


Modified:
    directory/network/trunk/src/test/org/apache/mina/examples/echoserver/ConnectorTest.java

Modified: directory/network/trunk/src/test/org/apache/mina/examples/echoserver/ConnectorTest.java
URL: http://svn.apache.org/viewcvs/directory/network/trunk/src/test/org/apache/mina/examples/echoserver/ConnectorTest.java?rev=165104&r1=165103&r2=165104&view=diff
==============================================================================
--- directory/network/trunk/src/test/org/apache/mina/examples/echoserver/ConnectorTest.java
(original)
+++ directory/network/trunk/src/test/org/apache/mina/examples/echoserver/ConnectorTest.java
Wed Apr 27 23:10:20 2005
@@ -175,7 +175,17 @@
             }
         }
         
-        Thread.sleep( 300 );
+        for( int i = 0; i < 30; i++ ) {
+            if( readBuf.position() == 160 )
+            {
+                break;
+            }
+            else
+            {
+                Thread.sleep( 100 );
+            }
+        }
+
         session.close( true );
         
         Assert.assertEquals( 160, readBuf.position() );



Mime
View raw message