Search in sources :

Example 1 with ServiceBrokerInvalidOriginatingIdentityException

use of org.springframework.cloud.servicebroker.exception.ServiceBrokerInvalidOriginatingIdentityException in project spring-cloud-open-service-broker by spring-cloud.

the class ServiceBrokerExceptionHandlerTest method serviceBrokerInvalidOriginatingIdentityException.

@Test
void serviceBrokerInvalidOriginatingIdentityException() {
    ServiceBrokerInvalidOriginatingIdentityException exception = new ServiceBrokerInvalidOriginatingIdentityException("test message");
    ErrorMessage errorMessage = exceptionHandler.handleException(exception);
    assertThat(errorMessage.getError()).isNull();
    assertThat(errorMessage.getMessage()).contains("test message");
}
Also used : ServiceBrokerInvalidOriginatingIdentityException(org.springframework.cloud.servicebroker.exception.ServiceBrokerInvalidOriginatingIdentityException) ErrorMessage(org.springframework.cloud.servicebroker.model.error.ErrorMessage) Test(org.junit.jupiter.api.Test)

Aggregations

Test (org.junit.jupiter.api.Test)1 ServiceBrokerInvalidOriginatingIdentityException (org.springframework.cloud.servicebroker.exception.ServiceBrokerInvalidOriginatingIdentityException)1 ErrorMessage (org.springframework.cloud.servicebroker.model.error.ErrorMessage)1