use of org.opensmartgridplatform.adapter.ws.schema.smartmetering.bundle.FaultResponse in project open-smart-grid-platform by OSGP.
the class BundleSteps method theBundleResponseShouldBeAFaultResponseWithMessageContaining.
@Then("the bundle response should be a FaultResponse with message containing")
public void theBundleResponseShouldBeAFaultResponseWithMessageContaining(final Map<String, String> values) throws Throwable {
final Response response = this.getNextBundleResponse();
assertThat(response).isInstanceOf(FaultResponse.class);
assertThat(response.getResult()).isEqualTo(OsgpResultType.NOT_OK);
final FaultResponse faultResponse = (FaultResponse) response;
assertThat(faultResponse.getMessage()).containsSubsequence(values.get(PlatformKeys.MESSAGE));
}
Aggregations