use of com.evolveum.midpoint.task.api.TaskManagerException in project midpoint by Evolveum.
the class TestSanityLegacy method test999Shutdown.
@Test
public void test999Shutdown() throws Exception {
taskManager.shutdown();
waitFor("waiting for task manager shutdown", new Checker() {
@Override
public boolean check() throws CommonException {
try {
return taskManager.getLocallyRunningTasks(new OperationResult("dummy")).isEmpty();
} catch (TaskManagerException e) {
throw new SystemException(e);
}
}
@Override
public void timeout() {
// No reaction, the test will fail right after return from this
}
}, 10000);
AssertJUnit.assertEquals("Some tasks left running after shutdown", new HashSet<Task>(), taskManager.getLocallyRunningTasks(new OperationResult("dummy")));
}
use of com.evolveum.midpoint.task.api.TaskManagerException in project midpoint by Evolveum.
the class ConsistencyTest method test999Shutdown.
@Test
public void test999Shutdown() throws Exception {
taskManager.shutdown();
waitFor("waiting for task manager shutdown", new Checker() {
@Override
public boolean check() throws CommonException {
try {
return taskManager.getLocallyRunningTasks(new OperationResult("dummy")).isEmpty();
} catch (TaskManagerException e) {
throw new SystemException(e);
}
}
@Override
public void timeout() {
// No reaction, the test will fail right after return from this
}
}, 10000);
AssertJUnit.assertEquals("Some tasks left running after shutdown", new HashSet<Task>(), taskManager.getLocallyRunningTasks(new OperationResult("dummy")));
}
use of com.evolveum.midpoint.task.api.TaskManagerException in project midpoint by Evolveum.
the class TestSanity method test999Shutdown.
@Test
public void test999Shutdown() throws Exception {
taskManager.shutdown();
waitFor("waiting for task manager shutdown", new Checker() {
@Override
public boolean check() throws CommonException {
try {
return taskManager.getLocallyRunningTasks(new OperationResult("dummy")).isEmpty();
} catch (TaskManagerException e) {
throw new SystemException(e);
}
}
@Override
public void timeout() {
// No reaction, the test will fail right after return from this
}
}, 10000);
AssertJUnit.assertEquals("Some tasks left running after shutdown", new HashSet<Task>(), taskManager.getLocallyRunningTasks(new OperationResult("dummy")));
}
Aggregations