public void run() {
        val client = getClient();
        val context = MockWebContext.create();
        final SessionStore sessionStore = new MockSessionStore();
        val url = ((FoundAction) client.getRedirectionAction(new CallContext(context, sessionStore)).get()).getLocation();
        logger.warn("Redirect to: \n{}", url);
        if (StringUtils.isNotBlank(getLogin()) && StringUtils.isNotBlank(getPassword())) {
            logger.warn("Use credentials: {} / {}", getLogin(), getPassword());
        } else {
            logger.warn("Use your own personal credentials");
        }
        if (canCancel()) {
            logger.warn("You can CANCEL the authentication.");
        }
        logger.warn("Returned url (copy/paste the fragment starting before the question mark of the query string):");
        val scanner = new Scanner(System.in, StandardCharsets.UTF_8.name());
        val returnedUrl = scanner.nextLine().trim();
        populateContextWithUrl(context, returnedUrl);
        val credentials = client.getCredentials(new CallContext(context, sessionStore));
        if (credentials.isPresent()) {
            val profile = client.getUserProfile(new CallContext(context, sessionStore), credentials.get());
            logger.debug("userProfile: {}", profile);
            if (profile.isPresent() || !canCancel()) {
                verifyProfile((CommonProfile) profile.get());
                logger.warn("## Java serialization");
                val javaSerializer = new JavaSerializer();
                var bytes = javaSerializer.serializeToBytes(profile.get());
                val profile2 = (CommonProfile) javaSerializer.deserializeFromBytes(bytes);
                verifyProfile(profile2);
            }
        }
        logger.warn("################");
        logger.warn("Test successful!");
    }
Run manually a test for a client.

@author Jerome Leleu
@since 1.9.0
pac4j-core/src/test/java/org/pac4j/core/run/RunClient.java