@Test
    void verifyOperationWithValidTicket() throws Throwable {
        val request = getHttpRequestForEndpoint(OidcConstants.INTROSPECTION_URL);
        val response = new MockHttpServletResponse();

        val value = EncodingUtils.encodeBase64("clientid:secret".getBytes(StandardCharsets.UTF_8));
        request.addHeader(HttpConstants.AUTHORIZATION_HEADER, HttpConstants.BASIC_HEADER_PREFIX + value);

        val accessToken = getAccessToken();
        servicesManager.save(getOidcRegisteredService());
        ticketRegistry.addTicket(accessToken);
        request.addParameter(OAuth20Constants.TOKEN, accessToken.getId());
        val result = oidcIntrospectionEndpointController.handleRequest(request, response);
        val body = (OAuth20IntrospectionAccessTokenResponse) result.getBody();
        assertNotNull(body);
        assertTrue(Instant.ofEpochSecond(body.getExp()).isAfter(Instant.ofEpochSecond(body.getIat())));
        assertTrue(body.isActive());
        assertEquals(accessToken.getScopes(), Set.of(body.getScope().split(" ")));
    }
This is {@link OidcIntrospectionEndpointControllerTests}.

@author Misagh Moayyed
@since 6.1.0
support/cas-server-support-oidc/src/test/java/org/apereo/cas/oidc/web/controllers/OidcIntrospectionEndpointControllerTests.java