Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(9)

Side by Side Diff: chrome/test/base/testing_profile.h

Issue 2928823003: Make it possible to build without enable_supervised_users.
Patch Set: Does it still compile with the feature enabled? Created 3 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « chrome/test/BUILD.gn ('k') | chrome/test/base/testing_profile.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CHROME_TEST_BASE_TESTING_PROFILE_H_ 5 #ifndef CHROME_TEST_BASE_TESTING_PROFILE_H_
6 #define CHROME_TEST_BASE_TESTING_PROFILE_H_ 6 #define CHROME_TEST_BASE_TESTING_PROFILE_H_
7 7
8 #include <memory> 8 #include <memory>
9 #include <string> 9 #include <string>
10 #include <utility> 10 #include <utility>
11 #include <vector> 11 #include <vector>
12 12
13 #include "base/files/scoped_temp_dir.h" 13 #include "base/files/scoped_temp_dir.h"
14 #include "base/macros.h" 14 #include "base/macros.h"
15 #include "base/memory/ref_counted.h" 15 #include "base/memory/ref_counted.h"
16 #include "build/build_config.h" 16 #include "build/build_config.h"
17 #include "chrome/browser/profiles/profile.h" 17 #include "chrome/browser/profiles/profile.h"
18 #include "chrome/common/features.h"
18 #include "components/domain_reliability/clear_mode.h" 19 #include "components/domain_reliability/clear_mode.h"
19 #include "components/keyed_service/content/browser_context_keyed_service_factory .h" 20 #include "components/keyed_service/content/browser_context_keyed_service_factory .h"
20 #include "extensions/features/features.h" 21 #include "extensions/features/features.h"
21 22
22 #if defined(OS_CHROMEOS) 23 #if defined(OS_CHROMEOS)
23 #include "chrome/browser/chromeos/settings/scoped_cros_settings_test_helper.h" 24 #include "chrome/browser/chromeos/settings/scoped_cros_settings_test_helper.h"
24 #endif 25 #endif
25 26
26 class BrowserContextDependencyManager; 27 class BrowserContextDependencyManager;
27 class ExtensionSpecialStoragePolicy; 28 class ExtensionSpecialStoragePolicy;
(...skipping 345 matching lines...) Expand 10 before | Expand all | Expand 10 after
373 374
374 // Common initialization between the two constructors. 375 // Common initialization between the two constructors.
375 void Init(); 376 void Init();
376 377
377 // Finishes initialization when a profile is created asynchronously. 378 // Finishes initialization when a profile is created asynchronously.
378 void FinishInit(); 379 void FinishInit();
379 380
380 // Creates a TestingPrefService and associates it with the TestingProfile. 381 // Creates a TestingPrefService and associates it with the TestingProfile.
381 void CreateTestingPrefService(); 382 void CreateTestingPrefService();
382 383
384 #if BUILDFLAG(ENABLE_SUPERVISED_USERS)
383 // Creates a pref service that uses SupervisedUserPrefStore and associates 385 // Creates a pref service that uses SupervisedUserPrefStore and associates
384 // it with the TestingProfile. 386 // it with the TestingProfile.
385 void CreatePrefServiceForSupervisedUser(); 387 void CreatePrefServiceForSupervisedUser();
388 #endif
386 389
387 // Initializes |prefs_| for an incognito profile, derived from 390 // Initializes |prefs_| for an incognito profile, derived from
388 // |original_profile_|. 391 // |original_profile_|.
389 void CreateIncognitoPrefService(); 392 void CreateIncognitoPrefService();
390 393
391 // Creates a ProfilePolicyConnector that the ProfilePolicyConnectorFactory 394 // Creates a ProfilePolicyConnector that the ProfilePolicyConnectorFactory
392 // maps to this profile. 395 // maps to this profile.
393 void CreateProfilePolicyConnector(); 396 void CreateProfilePolicyConnector();
394 397
395 // Internally, this is a TestURLRequestContextGetter that creates a dummy 398 // Internally, this is a TestURLRequestContextGetter that creates a dummy
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
444 447
445 #if defined(OS_CHROMEOS) 448 #if defined(OS_CHROMEOS)
446 std::unique_ptr<chromeos::ScopedCrosSettingsTestHelper> 449 std::unique_ptr<chromeos::ScopedCrosSettingsTestHelper>
447 scoped_cros_settings_test_helper_; 450 scoped_cros_settings_test_helper_;
448 #endif // defined(OS_CHROMEOS) 451 #endif // defined(OS_CHROMEOS)
449 452
450 std::unique_ptr<policy::PolicyService> policy_service_; 453 std::unique_ptr<policy::PolicyService> policy_service_;
451 }; 454 };
452 455
453 #endif // CHROME_TEST_BASE_TESTING_PROFILE_H_ 456 #endif // CHROME_TEST_BASE_TESTING_PROFILE_H_
OLDNEW
« no previous file with comments | « chrome/test/BUILD.gn ('k') | chrome/test/base/testing_profile.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698