14e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)// Copyright 2013 The Chromium Authors. All rights reserved.
24e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)// Use of this source code is governed by a BSD-style license that can be
34e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)// found in the LICENSE file.
44e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)
54e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)#ifndef CHROME_BROWSER_UI_APP_LIST_TEST_FAKE_PROFILE_H_
64e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)#define CHROME_BROWSER_UI_APP_LIST_TEST_FAKE_PROFILE_H_
74e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)
84e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)#include "base/files/file_path.h"
94e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)#include "base/memory/ref_counted.h"
104e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)#include "base/sequenced_task_runner.h"
114e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)#include "chrome/browser/profiles/profile.h"
12cedac228d2dd51db4b79ea1e72c7f249408ee061Torne (Richard Coles)#include "components/domain_reliability/clear_mode.h"
134e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)#include "content/public/browser/browser_context.h"
144e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)
154e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)class ResourceContext;
164e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)
174e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)namespace net {
184e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)class URLRequestContextGetter;
194e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)}
204e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)
214e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)namespace content {
224e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)class DownloadManagerDelegate;
234e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)class ResourceContext;
245f1c94371a64b3196d4be9466099bb892df9b88eTorne (Richard Coles)class SSLHostStateDelegate;
254e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)}
264e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)
274e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)class FakeProfile : public Profile {
284e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles) public:
294e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  explicit FakeProfile(const std::string& name);
304e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  FakeProfile(const std::string& name, const base::FilePath& path);
314e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)
324e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  // Profile overrides.
334e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual std::string GetProfileName() OVERRIDE;
34a1401311d1ab56c4ed0a474bd38c108f75cb0cd9Torne (Richard Coles)  virtual ProfileType GetProfileType() const OVERRIDE;
354e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual base::FilePath GetPath() const OVERRIDE;
364e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual bool IsOffTheRecord() const OVERRIDE;
374e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual content::DownloadManagerDelegate*
384e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)      GetDownloadManagerDelegate() OVERRIDE;
394e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual net::URLRequestContextGetter* GetRequestContextForRenderProcess(
404e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)      int renderer_child_id) OVERRIDE;
414e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual net::URLRequestContextGetter* GetMediaRequestContext() OVERRIDE;
424e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual net::URLRequestContextGetter* GetMediaRequestContextForRenderProcess(
434e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)      int renderer_child_id) OVERRIDE;
444e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual net::URLRequestContextGetter*
454e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)      GetMediaRequestContextForStoragePartition(
464e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)          const base::FilePath& partition_path,
474e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)          bool in_memory) OVERRIDE;
484e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual content::ResourceContext* GetResourceContext() OVERRIDE;
49cedac228d2dd51db4b79ea1e72c7f249408ee061Torne (Richard Coles)  virtual content::BrowserPluginGuestManager* GetGuestManager() OVERRIDE;
5003b57e008b61dfcb1fbad3aea950ae0e001748b0Torne (Richard Coles)  virtual storage::SpecialStoragePolicy* GetSpecialStoragePolicy() OVERRIDE;
51f8ee788a64d60abd8f2d742a5fdedde054ecd910Torne (Richard Coles)  virtual content::PushMessagingService* GetPushMessagingService() OVERRIDE;
525f1c94371a64b3196d4be9466099bb892df9b88eTorne (Richard Coles)  virtual content::SSLHostStateDelegate* GetSSLHostStateDelegate() OVERRIDE;
534e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual scoped_refptr<base::SequencedTaskRunner> GetIOTaskRunner() OVERRIDE;
544e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual Profile* GetOffTheRecordProfile() OVERRIDE;
554e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual void DestroyOffTheRecordProfile() OVERRIDE;
564e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual bool HasOffTheRecordProfile() OVERRIDE;
574e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual Profile* GetOriginalProfile() OVERRIDE;
58f8ee788a64d60abd8f2d742a5fdedde054ecd910Torne (Richard Coles)  virtual bool IsSupervised() OVERRIDE;
594e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual history::TopSites* GetTopSites() OVERRIDE;
604e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual history::TopSites* GetTopSitesWithoutCreating() OVERRIDE;
614e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual ExtensionSpecialStoragePolicy*
624e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)      GetExtensionSpecialStoragePolicy() OVERRIDE;
634e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual PrefService* GetPrefs() OVERRIDE;
644e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual PrefService* GetOffTheRecordPrefs() OVERRIDE;
654e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual net::URLRequestContextGetter* GetRequestContext() OVERRIDE;
664e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual net::URLRequestContextGetter*
674e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)      GetRequestContextForExtensions() OVERRIDE;
684e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual net::SSLConfigService* GetSSLConfigService() OVERRIDE;
694e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual HostContentSettingsMap* GetHostContentSettingsMap() OVERRIDE;
704e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual bool IsSameProfile(Profile* profile) OVERRIDE;
714e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual base::Time GetStartTime() const OVERRIDE;
724e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual net::URLRequestContextGetter* CreateRequestContext(
73a1401311d1ab56c4ed0a474bd38c108f75cb0cd9Torne (Richard Coles)      content::ProtocolHandlerMap* protocol_handlers,
74cedac228d2dd51db4b79ea1e72c7f249408ee061Torne (Richard Coles)      content::URLRequestInterceptorScopedVector request_interceptors) OVERRIDE;
754e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual net::URLRequestContextGetter* CreateRequestContextForStoragePartition(
764e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)      const base::FilePath& partition_path,
774e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)      bool in_memory,
78a1401311d1ab56c4ed0a474bd38c108f75cb0cd9Torne (Richard Coles)      content::ProtocolHandlerMap* protocol_handlers,
79cedac228d2dd51db4b79ea1e72c7f249408ee061Torne (Richard Coles)      content::URLRequestInterceptorScopedVector request_interceptors) OVERRIDE;
804e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual base::FilePath last_selected_directory() OVERRIDE;
814e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual void set_last_selected_directory(const base::FilePath& path) OVERRIDE;
824e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)
834e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)#if defined(OS_CHROMEOS)
844e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual void ChangeAppLocale(
854e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)      const std::string& locale, AppLocaleChangedVia via) OVERRIDE;
864e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual void OnLogin() OVERRIDE;
874e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual void InitChromeOSPreferences() OVERRIDE;
884e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)#endif  // defined(OS_CHROMEOS)
894e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)
904e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual PrefProxyConfigTracker* GetProxyConfigTracker() OVERRIDE;
914e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual chrome_browser_net::Predictor* GetNetworkPredictor() OVERRIDE;
9246d4c2bc3267f3f028f39e7e311b0f89aba2e4fdTorne (Richard Coles)  virtual DevToolsNetworkController* GetDevToolsNetworkController() OVERRIDE;
934e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual void ClearNetworkingHistorySince(
944e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)      base::Time time, const base::Closure& completion) OVERRIDE;
954e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual GURL GetHomePage() OVERRIDE;
964e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual bool WasCreatedByVersionOrLater(const std::string& version) OVERRIDE;
974e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual void SetExitType(ExitType exit_type) OVERRIDE;
984e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  virtual ExitType GetLastSessionExitType() OVERRIDE;
994e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)
1004e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles) private:
1014e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  std::string name_;
1024e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)  base::FilePath path_;
1034e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)};
1044e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)
1054e180b6a0b4720a9b8e9e959a882386f690f08ffTorne (Richard Coles)#endif  // CHROME_BROWSER_UI_APP_LIST_TEST_FAKE_PROFILE_H_
106