use of com.axway.apim.setup.APIManagerSettingsApp in project apim-cli by Axway-API-Management-Plus.
the class ExportManagerConfigTestAction method runTest.
@Override
public ExportResult runTest(TestContext context) {
APIManagerSetupExportParams params = new APIManagerSetupExportParams();
addParameters(params, context);
params.setRemoteHostName(getVariable(context, PARAM_NAME));
params.setRemoteHostId(getVariable(context, PARAM_ID));
APIManagerSettingsApp app = new APIManagerSettingsApp();
LOG.info("Running " + app.getClass().getSimpleName() + " with params: " + params);
ExportResult result = app.runExport(params);
if (this.getExpectedReturnCode(context) != result.getRc()) {
throw new ValidationException("Expected RC was: " + this.getExpectedReturnCode(context) + " but got: " + result.getRc());
}
return result;
}
use of com.axway.apim.setup.APIManagerSettingsApp in project apim-cli by Axway-API-Management-Plus.
the class ImportManagerConfigTestAction method runTest.
@Override
public void runTest(TestContext context) {
StandardImportParams params = new StandardImportParams();
addParameters(params, context);
params.setConfig(this.configFile.getPath());
APIManagerSettingsApp app = new APIManagerSettingsApp();
LOG.info("Running " + app.getClass().getSimpleName() + " with params: " + params);
ImportResult result = app.importConfig(params);
if (this.getExpectedReturnCode(context) != result.getRc()) {
throw new ValidationException("Expected RC was: " + this.getExpectedReturnCode(context) + " but got: " + result.getRc());
}
}
Aggregations