protected OAuthRegisteredService addRegisteredService(final Set<OAuth20GrantTypes> grantTypes,
                                                          final String clientId,
                                                          final String clientSecret,
                                                          final String redirectUri) {
        val registeredService = getRegisteredService(redirectUri, clientId, clientSecret, grantTypes);
        servicesManager.save(registeredService);
        return registeredService;
    }
This is {@link AbstractOAuth20Tests}.

@author Misagh Moayyed
@since 5.0.0
support/cas-server-support-oauth/src/test/java/org/apereo/cas/AbstractOAuth20Tests.java