fake_oauth2_token_service.cc revision 5d1f7b1de12d16ceb2c938c56701a3e8bfa558f7
15d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles)// Copyright 2014 The Chromium Authors. All rights reserved. 25d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles)// Use of this source code is governed by a BSD-style license that can be 35d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles)// found in the LICENSE file. 45d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles) 55d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles)#include "google_apis/gaia/fake_oauth2_token_service.h" 65d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles) 75d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles)FakeOAuth2TokenService::FakeOAuth2TokenService() { 85d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles)} 95d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles) 105d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles)FakeOAuth2TokenService::~FakeOAuth2TokenService() { 115d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles)} 125d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles) 135d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles)std::string FakeOAuth2TokenService::GetRefreshToken( 145d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles) const std::string& account_id) { 155d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles) return std::string(); 165d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles)} 175d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles) 185d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles)void FakeOAuth2TokenService::FetchOAuth2Token( 195d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles) RequestImpl* request, 205d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles) const std::string& account_id, 215d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles) net::URLRequestContextGetter* getter, 225d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles) const std::string& client_id, 235d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles) const std::string& client_secret, 245d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles) const ScopeSet& scopes) { 255d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles)} 265d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles) 275d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles)void FakeOAuth2TokenService::InvalidateOAuth2Token( 285d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles) const std::string& account_id, 295d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles) const std::string& client_id, 305d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles) const ScopeSet& scopes, 315d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles) const std::string& access_token) { 325d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles)} 335d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles) 345d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles)net::URLRequestContextGetter* FakeOAuth2TokenService::GetRequestContext() { 355d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles) return NULL; 365d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles)} 37