Fix compatibility with latest stable oauth2-client library, fixes tests