@Test
    void verifyAttributeDefinitions() {
        val registeredService = SamlIdPTestUtils.getSamlRegisteredService();
        val policy = new InCommonRSAttributeReleasePolicy();
        policy.setUseUniformResourceName(true);

        val context = RegisteredServiceAttributeReleasePolicyContext.builder()
            .registeredService(registeredService)
            .applicationContext(applicationContext)
            .service(CoreAuthenticationTestUtils.getService("https://sp.testshib.org/shibboleth-sp"))
            .principal(CoreAuthenticationTestUtils.getPrincipal("casuser"))
            .build();
        var definitions = policy.determineRequestedAttributeDefinitions(context);
        assertTrue(definitions.containsAll(InCommonRSAttributeReleasePolicy.ALLOWED_ATTRIBUTES.values()));

        policy.setUseUniformResourceName(false);
        definitions = policy.determineRequestedAttributeDefinitions(context);
        assertTrue(definitions.containsAll(InCommonRSAttributeReleasePolicy.ALLOWED_ATTRIBUTES.keySet()));
    }
This is {@link InCommonRSAttributeReleasePolicyTests}.

@author Misagh Moayyed
@since 6.1.0
support/cas-server-support-saml-idp/src/test/java/org/apereo/cas/support/saml/services/InCommonRSAttributeReleasePolicyTests.java