def test_get_auth_token_with_incorrect_response_1(): with pytest.raises(RefreshTokenException): SimpleAuthTokenProvider(MockWebClient(None, None)).get_new_token()
def get_client_with_default_response( response: RequestResponse = RequestResponse(None, None)) -> WebClient: return MockWebClient(default_response=response, interceptors=[TwitterAuthWebClientInterceptor()])