private Ticket prepCredential(final MockRequestContext context, final String principal, final String clientName) throws Exception {
        val sessionIdx = UUID.randomUUID().toString();
        val clientCredentials = getClientCredential(context, sessionIdx, clientName);
        val tgt = new MockTicketGrantingTicket(principal, clientCredentials, Map.of("sessionindex", List.of(sessionIdx)));
        configurationContext.getTicketRegistry().addTicket(tgt);
        WebUtils.putCredential(context, clientCredentials);
        return tgt;
    }
This is {@link DelegatedAuthenticationIdentityProviderLogoutActionTests}.

@author Misagh Moayyed
@since 7.0.0
support/cas-server-support-pac4j-saml/src/test/java/org/apereo/cas/web/saml2/DelegatedAuthenticationIdentityProviderLogoutActionTests.java