public void testClientTransactionMaxRetransmisssionsConfigurationParameter() throws Exception {
  System.setProperty(StackProperties.MAX_CTRAN_RETRANSMISSIONS,"2");
  System.setProperty(StackProperties.PROPAGATE_RECEIVED_RETRANSMISSIONS,"true");
  stunStack.addRequestListener(serverAddress,requestCollector);
  stunStack.sendRequest(bindingRequest,serverAddress,clientAddress,responseCollector);
  Thread.sleep(1600);
  Vector<StunMessageEvent> reqs=requestCollector.getRequestsForTransaction(bindingRequest.getTransactionID());
  assertTrue("No retransmissions of the request have been received",reqs.size() > 1);
  assertEquals("The MAX_RETRANSMISSIONS param was not taken into account!",reqs.size(),3);
}

public void testClientTransactionMaxRetransmisssionsConfigurationParameter ( ) throws Exception { System . setProperty ( StackProperties . MAX_CTRAN_RETRANSMISSIONS , "2" ) ; System . setProperty ( StackProperties . PROPAGATE_RECEIVED_RETRANSMISSIONS , "true" ) ; stunStack . addRequestListener ( serverAddress , requestCollector ) ; stunStack . sendRequest ( bindingRequest , serverAddress , clientAddress , responseCollector ) ; Thread . sleep ( 1600 ) ; Vector < StunMessageEvent > reqs = requestCollector . getRequestsForTransaction ( bindingRequest . getTransactionID ( ) ) ; assertTrue ( "No retransmissions of the request have been received" , reqs . size ( ) > 1 ) ; assertEquals ( "The MAX_RETRANSMISSIONS param was not taken into account!" , reqs . size ( ) , 3 ) ; }
tests whether the properties for configuring the maximum number of retransmissions in a transaction are working properly .
