use of com.emc.sa.engine.service.ServiceNotFoundException in project coprhd-controller by CoprHD.
the class ExecutionEngineImplTest method testErrorCreatingService.
@Test
public void testErrorCreatingService() {
ExecutionEngineImpl engine = new ExecutionEngineImpl();
engine.setModelClient(modelClient);
engine.setServiceFactory(new ExecutionServiceFactory() {
@Override
public ExecutionService createService(Order order, CatalogService catalogService) throws ServiceNotFoundException {
throw new RuntimeException("Unexpected error");
}
});
Order order = executeOrder(engine, createOrder("ErrorCreatingService"));
Assert.assertEquals(OrderStatus.ERROR.name(), order.getOrderStatus());
}
Aggregations