@Test public void executeWithResource() { GetDMNModelCommand getDMNModelCommand = new GetDMNModelCommand(resource.getSourcePath()); assertThatThrownBy(() -> getDMNModelCommand.execute(registryContext)) .isInstanceOf(IllegalStateException.class) .hasMessage("There is no DMNRuntime available"); registryContext.register(DMNRuntime.class, dmnRuntime); DMNModel dmnModel = getDMNModelCommand.execute(registryContext); assertEquals(resource.getSourcePath(), dmnModel.getResource().getSourcePath()); }
@Override public DMNModel execute(Context context) { return getDMNModel(context); }
GetDMNModelCommand extends AbstractDMNModelCommand { @Override public DMNModel execute(Context context) { return getDMNModel(context); } }
GetDMNModelCommand extends AbstractDMNModelCommand { @Override public DMNModel execute(Context context) { return getDMNModel(context); } GetDMNModelCommand(String namespace, String modelName);  GetDMNModelCommand(String resourcePath); }
GetDMNModelCommand extends AbstractDMNModelCommand { @Override public DMNModel execute(Context context) { return getDMNModel(context); } GetDMNModelCommand(String namespace, String modelName);  GetDMNModelCommand(String resourcePath); @Override DMNModel execute(Context context); }
GetDMNModelCommand extends AbstractDMNModelCommand { @Override public DMNModel execute(Context context) { return getDMNModel(context); } GetDMNModelCommand(String namespace, String modelName);  GetDMNModelCommand(String resourcePath); @Override DMNModel execute(Context context);  }