@Test
        void verifyOidcLogoutWithIdTokenAndStateParams() throws Throwable {
            val oidcRegisteredService = getOidcRegisteredService(UUID.randomUUID().toString(), randomServiceUrl(), true, false);
            val claims = getClaims(oidcRegisteredService.getClientId());
            servicesManager.save(oidcRegisteredService);
            val idToken = oidcTokenSigningAndEncryptionService.encode(oidcRegisteredService, claims);

            val request = mockMvc.perform(get("/cas/oidc/logout")
                    .with(withHttpRequestProcessor())
                    .queryParam(OidcConstants.ID_TOKEN_HINT, idToken)
                    .queryParam(OAuth20Constants.STATE, "abcd1234")
                )
                .andExpect(status().isOk())
                .andExpect(request().attribute("status", HttpStatus.PERMANENT_REDIRECT))
                .andReturn()
                .getRequest();

            val redirectUrl = WebUtils.getLogoutRedirectUrl(request, String.class);
            assertEquals("https://oauth.example.org/logout?state=abcd1234&client_id=%s".formatted(oidcRegisteredService.getClientId()), redirectUrl);
        }
This is {@link OidcLogoutEndpointControllerTests}.

@author Julien Huon
@since 6.1.0
support/cas-server-support-oidc/src/test/java/org/apereo/cas/oidc/web/controllers/logout/OidcLogoutEndpointControllerTests.java