@Test
    void checkAuthzPrincipalWithAttrRequirementsNoValueMatch() throws Throwable {
        val authz = new DefaultRegisteredServiceAccessStrategy();
        val reqs = getRequiredAttributes();
        reqs.remove(PHONE);
        authz.setRequiredAttributes(reqs);
        authz.setRequireAllAttributes(false);
        val pAttrs = getPrincipalAttributes();
        pAttrs.remove(CN);
        pAttrs.put(GIVEN_NAME, "theName");
        assertFalse(authz.authorizeRequest(RegisteredServiceAccessStrategyRequest.builder().applicationContext(applicationContext)
            .principalId(TEST).attributes(pAttrs).build()));
    }
This is test cases for
{@link DefaultRegisteredServiceAccessStrategy}.

@author Misagh Moayyed
@since 4.1
core/cas-server-core-services/src/test/java/org/apereo/cas/services/DefaultRegisteredServiceAccessStrategyTests.java