Code example for TimeUnit

Methods: sleep

0
    } 
  } 
   
  @Test(dependsOnGroups = "msg") 
  public void messages() throws InterruptedException { 
    TimeUnit.SECONDS.sleep(10);
    List<Message> messageList = this.client.getAndClearMessages();
    System.out.println(messageList);
  } 
 
  @Test(dependsOnGroups = "msg") 
  public void close() throws IOException { 
    client.close();
  } 
 
}