protected static X509Certificate[] createCertificates(final String... files) {
        val certs = new X509Certificate[files.length];

        var i = 0;
        for (val file : files) {
            try {
                certs[i++] = CertUtil.readCertificate(new ClassPathResource(file).getInputStream());
            } catch (final Exception e) {
                throw new IllegalArgumentException("Error creating certificate at " + file, e);
            }
        }
        return certs;
    }
Unit test for {@link X509CredentialsAuthenticationHandler} class.

@author Scott Battaglia
@author Marvin S. Addison
@since 3.0.0
support/cas-server-support-x509-core/src/test/java/org/apereo/cas/adaptors/x509/authentication/handler/support/X509CredentialsAuthenticationHandlerTests.java