@Test
    void verifyOperation() {
        val resource = new ClassPathResource("directory/cas.groovy");
        val configurationLoaders = CasConfigurationPropertiesSourceLocator.getConfigurationPropertiesLoaders();
        val foundLoader = configurationLoaders
            .stream()
            .filter(loader -> loader.supports(resource))
            .findFirst()
            .orElseThrow();
        val source = foundLoader.load(resource, environment, "groovyConfig", CipherExecutor.noOpOfStringToString());
        assertEquals("true", source.getProperty("cas.service-registry.core.init-from-json"));
        assertEquals("test::dev", source.getProperty("cas.authn.accept.users"));
        assertEquals("Static", source.getProperty("cas.authn.accept.name"));
    }
This is {@link ConfigurationPropertiesLoaderFactoryTests}.

@author Misagh Moayyed
@since 7.0.0
core/cas-server-core-configuration/src/test/java/org/apereo/cas/configuration/loader/ConfigurationPropertiesLoaderFactoryTests.java