@Test
        void verifyFailedAuthentication() throws Throwable {
            val context = MockRequestContext.create(applicationContext).withUserAgent().setClientInfo();
            context.setParameter("error_message", "bad authn");
            context.setParameter("error_code", "403");
            context.setParameter("error_description", "authentication failed");
            val service = CoreAuthenticationTestUtils.getService();
            context.setParameter(CasProtocolConstants.PARAMETER_SERVICE, service.getId());

            assertEquals(CasWebflowConstants.TRANSITION_ID_STOP, delegatedAuthenticationAction.execute(context).getId());
        }
This class tests the {@link DelegatedClientAuthenticationAction} class.

@author Jerome Leleu
@since 3.5.2
support/cas-server-support-pac4j-webflow/src/test/java/org/apereo/cas/web/flow/actions/DelegatedClientAuthenticationActionTests.java