@Test
    void createX509Credential() throws IOException {
        val request = new MockHttpServletRequest();
        try (val scan = new Scanner(new ClassPathResource("ldap-crl.crt").getFile(), StandardCharsets.UTF_8)) {
            val certStr = scan.useDelimiter("\\Z").next();
            request.addHeader(HEADER, certStr);

            val cred = factory.fromRequest(request, null).getFirst();
            assertInstanceOf(X509CertificateCredential.class, cred);
        }
    }
Unit tests for {@link X509RestMultipartBodyCredentialFactory}.

@author Dmytro Fedonin
@since 5.1.0
support/cas-server-support-rest-x509/src/test/java/org/apereo/cas/support/x509/rest/X509RestHttpRequestHeaderCredentialFactoryTests.java