You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by ma...@apache.org on 2013/08/20 12:23:23 UTC
svn commit: r1515761 -
/tomcat/trunk/test/org/apache/tomcat/websocket/pojo/TestEncodingDecoding.java
Author: markt
Date: Tue Aug 20 10:23:23 2013
New Revision: 1515761
URL: http://svn.apache.org/r1515761
Log:
Reduce a potential timing sensitivity
Modified:
tomcat/trunk/test/org/apache/tomcat/websocket/pojo/TestEncodingDecoding.java
Modified: tomcat/trunk/test/org/apache/tomcat/websocket/pojo/TestEncodingDecoding.java
URL: http://svn.apache.org/viewvc/tomcat/trunk/test/org/apache/tomcat/websocket/pojo/TestEncodingDecoding.java?rev=1515761&r1=1515760&r2=1515761&view=diff
==============================================================================
--- tomcat/trunk/test/org/apache/tomcat/websocket/pojo/TestEncodingDecoding.java (original)
+++ tomcat/trunk/test/org/apache/tomcat/websocket/pojo/TestEncodingDecoding.java Tue Aug 20 10:23:23 2013
@@ -161,7 +161,16 @@ public class TestEncodingDecoding extend
Assert.assertEquals(MESSAGE_ONE,
((MsgString) client.received.peek()).getData());
session.close();
- Thread.sleep(100);
+
+ // Should not take very long but some failures have been seen
+ i = 0;
+ while (i < 20) {
+ if (Server.isLifeCycleEventCalled(
+ MsgStringEncoder.class.getName()+":init")) {
+ break;
+ }
+ Thread.sleep(100);
+ }
Assert.assertTrue(Server.isLifeCycleEventCalled(
MsgStringEncoder.class.getName()+":init"));
Assert.assertTrue(Server.isLifeCycleEventCalled(
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org