Examples of AsynchronousFacade


Examples of org.jboss.aspects.asynchronous.aspects.AsynchronousFacade

    assertEquals("Cleanup method called", false, bm2.bCleanupCalled);
  }
  public static void testIsDone() {
    BusinessModel bm1 = new BusinessModel(200);
    bm1.processBusinessModel();
    AsynchronousFacade asynchronousFacade = (AsynchronousFacade)bm1;
    long t0 = System.currentTimeMillis();
    assertFalse("isDone returns TRUE  !", asynchronousFacade.isDone());
    long t1 = System.currentTimeMillis();
    assertTrue(
      "isDone is a blocking call " + (t1 - t0) + " ms.",
      (t1 - t0) < 20);
    assertEquals(
      "Method is not succesfull !",
      OK,
      asynchronousFacade.getResponseCode());
    assertTrue("isDone returns FALSE  !", asynchronousFacade.isDone());
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.