@Test
    public void testCentralLogout() {
        val profile = new CommonProfile();
        profile.setClientName(NAME);
        val client = new MockIndirectClient(NAME);
        client.setCallbackUrl(PAC4J_BASE_URL);
        client.setLogoutActionBuilder((ctx, p, targetUrl) -> Optional.of(new FoundAction(CALLBACK_URL + "?p=" + targetUrl)));
        config.setClients(new Clients(client));
        profiles.put(NAME, profile);
        addProfilesToContext();
        centralLogout = true;
        context.addRequestParameter(Pac4jConstants.URL, CALLBACK_URL);
        logoutUrlPattern = ".*";
        call();
        assertEquals(302, action.getCode());
        assertEquals(CALLBACK_URL + "?p=" + CALLBACK_URL, ((FoundAction) action).getLocation());
        expectedNProfiles(0);
    }
Tests {@link DefaultLogoutLogic}.

@author Jerome Leleu
@since 1.9.0
pac4j-core/src/test/java/org/pac4j/core/engine/DefaultLogoutLogicTests.java