|
Ensure incognito TestingProfiles are incognito for their whole lifetime.
Otherwise keyed services see different profiles in unit_tests at
different times since the incognito->GetOriginalProfile() changes. This
is causing release code to pick up unnecessary workarounds to keep
unit_tests green in try runs.
The fix is achieved by adding `TestingProfile::Builder::BuildIncognito`,
which differs from `Build` by requiring an |original_profile| argument,
which will own the incognito profile (so no need to return scoped_ptr).
This simplifies a lot of call sites, since they no longer need to do a
scoped_ptr dance of their own.
BUG= 277296
Committed: https://crrev.com/1ab9b709cb4d691f667c843040b65b46a9c82ebd
Cr-Commit-Position: refs/heads/master@{#294931}
Total comments: 13
|
Unified diffs |
Side-by-side diffs |
Delta from patch set |
Stats (+131 lines, -142 lines) |
Patch |
|
M |
chrome/browser/chromeos/policy/user_cloud_policy_manager_chromeos_unittest.cc
|
View
|
1
2
3
4
5
|
2 chunks |
+1 line, -5 lines |
0 comments
|
Download
|
|
M |
chrome/browser/chromeos/power/power_prefs_unittest.cc
|
View
|
1
2
|
1 chunk |
+2 lines, -9 lines |
0 comments
|
Download
|
|
M |
chrome/browser/content_settings/content_settings_pref_provider_unittest.cc
|
View
|
|
1 chunk |
+1 line, -3 lines |
0 comments
|
Download
|
|
M |
chrome/browser/password_manager/password_manager_internals_service_unittest.cc
|
View
|
|
3 chunks |
+7 lines, -3 lines |
0 comments
|
Download
|
|
M |
chrome/browser/profiles/profile_manager_unittest.cc
|
View
|
|
1 chunk |
+0 lines, -7 lines |
0 comments
|
Download
|
|
M |
chrome/browser/renderer_context_menu/spelling_menu_observer_browsertest.cc
|
View
|
1
2
|
3 chunks |
+8 lines, -6 lines |
0 comments
|
Download
|
|
M |
chrome/browser/search/hotword_service_unittest.cc
|
View
|
|
3 chunks |
+5 lines, -9 lines |
0 comments
|
Download
|
|
M |
chrome/browser/ui/autofill/account_chooser_model_unittest.cc
|
View
|
1
|
1 chunk |
+3 lines, -8 lines |
0 comments
|
Download
|
|
M |
chrome/browser/ui/bookmarks/bookmark_context_menu_controller_unittest.cc
|
View
|
1
|
1 chunk |
+2 lines, -8 lines |
0 comments
|
Download
|
|
M |
chrome/browser/ui/browser_command_controller_unittest.cc
|
View
|
1
2
|
2 chunks |
+9 lines, -10 lines |
0 comments
|
Download
|
|
M |
chrome/browser/ui/sync/one_click_signin_helper_unittest.cc
|
View
|
1
2
3
4
|
1 chunk |
+6 lines, -4 lines |
0 comments
|
Download
|
|
M |
chrome/browser/ui/views/bookmarks/bookmark_context_menu_unittest.cc
|
View
|
1
|
1 chunk |
+2 lines, -5 lines |
0 comments
|
Download
|
|
M |
chrome/test/base/testing_profile.h
|
View
|
1
2
3
4
5
6
|
8 chunks |
+16 lines, -9 lines |
0 comments
|
Download
|
|
M |
chrome/test/base/testing_profile.cc
|
View
|
1
2
3
4
5
6
|
17 chunks |
+66 lines, -49 lines |
0 comments
|
Download
|
|
M |
chrome/test/base/testing_profile_manager.cc
|
View
|
|
2 chunks |
+3 lines, -7 lines |
0 comments
|
Download
|
Total messages: 16 (9 generated)
|