@Test
    public void testInitGatewayForbidden() {
        val configuration = new CasConfiguration();
        configuration.setLoginUrl(LOGIN_URL);
        configuration.setGateway(true);
        val client = new DirectCasClient(configuration);
        TestsHelper.expectException(client::init, TechnicalException.class,
            "the DirectCasClient can not support gateway to avoid infinite loops");
    }
Tests the {@link DirectCasClient}.

@author Jerome Leleu
@since 1.9.2
pac4j-cas/src/test/java/org/pac4j/cas/client/direct/DirectCasClientTests.java