Search in sources :

Example 1 with StatusCodeBuilder

use of uk.gov.ida.saml.core.test.builders.StatusCodeBuilder in project verify-hub by alphagov.

the class ResponseValidatorTestHelper method createStatus.

public static Status createStatus(String statusCodeValue, StatusCode subStatusCode) {
    StatusCodeBuilder statusCodeBuilder = aStatusCode().withValue(statusCodeValue);
    StatusCode statusCode = subStatusCode == null ? statusCodeBuilder.build() : statusCodeBuilder.withSubStatusCode(subStatusCode).build();
    return aStatus().withStatusCode(statusCode).build();
}
Also used : StatusCodeBuilder(uk.gov.ida.saml.core.test.builders.StatusCodeBuilder) StatusCode(org.opensaml.saml.saml2.core.StatusCode) StatusCodeBuilder.aStatusCode(uk.gov.ida.saml.core.test.builders.StatusCodeBuilder.aStatusCode)

Aggregations

StatusCode (org.opensaml.saml.saml2.core.StatusCode)1 StatusCodeBuilder (uk.gov.ida.saml.core.test.builders.StatusCodeBuilder)1 StatusCodeBuilder.aStatusCode (uk.gov.ida.saml.core.test.builders.StatusCodeBuilder.aStatusCode)1