Thread.currentThread().sleep(2000);
if (!(ua.status() instanceof Completed)) {
ua.end();
fail("Activity status should be Completed " + ua.status());
}
if (!(ua.getCompletionStatus() instanceof Failure)) {
fail("Activity completion status should be Failure " + ua.getCompletionStatus());
}
System.out.println("Activity status: "+ua.status());