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

Issue 137383011: Expand PrefHashBrowserTest to ensure unloaded profile initialization produces proper hashes. (Closed)

Created:
6 years, 10 months ago by gab
Modified:
6 years, 10 months ago
CC:
chromium-reviews
Visibility:
Public.

Description

Expand PrefHashBrowserTest to ensure unloaded profile initialization produces proper hashes. This is done by ensuring that only Unchanged stats are generated when explicitly loading the second profile. This is a regression test for a regression that was about to be introduced in patch set 43 of https://codereview.chromium.org/114223002/#ps3400001 (basically the merge made it such that PrefHashFilter::Initialize -- which was just introduced after writting that CL -- would now use pref_hash_store_ directly to StoreHash where as this is wrong for split prefs; I will make this impossible in a following patch set of the afore-mentioned CL). The technique used to inspect histograms is akin to the one that was removed from the initial pref_metrics_service_unittest.cc in https://codereview.chromium.org/90563003. BUG=329078, 336478 TEST=New test passes on trunk, but fails on top of patch set 43 of afore-mentioned CL. Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=248032

Patch Set 1 #

Patch Set 2 : -empty line #

Total comments: 2

Patch Set 3 : -const nit #

Patch Set 4 : fix clang compile (remove unused variable) #

Total comments: 5

Patch Set 5 : Also inspect Settings.TrackedPreferencesInitializedForUnloadedProfile #

Unified diffs Side-by-side diffs Delta from patch set Stats (+98 lines, -3 lines) Patch
M chrome/browser/prefs/pref_hash_browsertest.cc View 1 2 3 4 5 chunks +98 lines, -3 lines 0 comments Download

Messages

Total messages: 12 (0 generated)
gab
Erik/Bernhard PTAL. Thanks! Gab
6 years, 10 months ago (2014-01-30 00:53:18 UTC) #1
Bernhard Bauer
lgtm https://codereview.chromium.org/137383011/diff/20001/chrome/browser/prefs/pref_hash_browsertest.cc File chrome/browser/prefs/pref_hash_browsertest.cc (right): https://codereview.chromium.org/137383011/diff/20001/chrome/browser/prefs/pref_hash_browsertest.cc#newcode70 chrome/browser/prefs/pref_hash_browsertest.cc:70: int GetTrackedPrefHistogramCount(const char* const histogram_name, Do we actually ...
6 years, 10 months ago (2014-01-30 10:36:52 UTC) #2
gab
Thanks, done. https://codereview.chromium.org/137383011/diff/20001/chrome/browser/prefs/pref_hash_browsertest.cc File chrome/browser/prefs/pref_hash_browsertest.cc (right): https://codereview.chromium.org/137383011/diff/20001/chrome/browser/prefs/pref_hash_browsertest.cc#newcode70 chrome/browser/prefs/pref_hash_browsertest.cc:70: int GetTrackedPrefHistogramCount(const char* const histogram_name, On 2014/01/30 ...
6 years, 10 months ago (2014-01-30 14:52:12 UTC) #3
erikwright (departed)
https://codereview.chromium.org/137383011/diff/60001/chrome/browser/prefs/pref_hash_browsertest.cc File chrome/browser/prefs/pref_hash_browsertest.cc (right): https://codereview.chromium.org/137383011/diff/60001/chrome/browser/prefs/pref_hash_browsertest.cc#newcode147 chrome/browser/prefs/pref_hash_browsertest.cc:147: I'm confused. I would have thought there would be ...
6 years, 10 months ago (2014-01-30 15:38:25 UTC) #4
gab
https://codereview.chromium.org/137383011/diff/60001/chrome/browser/prefs/pref_hash_browsertest.cc File chrome/browser/prefs/pref_hash_browsertest.cc (right): https://codereview.chromium.org/137383011/diff/60001/chrome/browser/prefs/pref_hash_browsertest.cc#newcode147 chrome/browser/prefs/pref_hash_browsertest.cc:147: On 2014/01/30 15:38:25, erikwright wrote: > I'm confused. I ...
6 years, 10 months ago (2014-01-30 15:58:52 UTC) #5
erikwright (departed)
https://codereview.chromium.org/137383011/diff/60001/chrome/browser/prefs/pref_hash_browsertest.cc File chrome/browser/prefs/pref_hash_browsertest.cc (right): https://codereview.chromium.org/137383011/diff/60001/chrome/browser/prefs/pref_hash_browsertest.cc#newcode147 chrome/browser/prefs/pref_hash_browsertest.cc:147: On 2014/01/30 15:58:52, gab wrote: > On 2014/01/30 15:38:25, ...
6 years, 10 months ago (2014-01-30 16:05:57 UTC) #6
gab
https://codereview.chromium.org/137383011/diff/60001/chrome/browser/prefs/pref_hash_browsertest.cc File chrome/browser/prefs/pref_hash_browsertest.cc (right): https://codereview.chromium.org/137383011/diff/60001/chrome/browser/prefs/pref_hash_browsertest.cc#newcode147 chrome/browser/prefs/pref_hash_browsertest.cc:147: On 2014/01/30 16:05:58, erikwright wrote: > On 2014/01/30 15:58:52, ...
6 years, 10 months ago (2014-01-30 16:19:18 UTC) #7
erikwright (departed)
https://codereview.chromium.org/137383011/diff/60001/chrome/browser/prefs/pref_hash_browsertest.cc File chrome/browser/prefs/pref_hash_browsertest.cc (right): https://codereview.chromium.org/137383011/diff/60001/chrome/browser/prefs/pref_hash_browsertest.cc#newcode147 chrome/browser/prefs/pref_hash_browsertest.cc:147: On 2014/01/30 16:19:18, gab wrote: > On 2014/01/30 16:05:58, ...
6 years, 10 months ago (2014-01-30 16:27:47 UTC) #8
gab
Perfect, added a check for Settings.TrackedPreferencesInitializedForUnloadedProfile in all 3 phases. Used the same method and ...
6 years, 10 months ago (2014-01-30 17:15:42 UTC) #9
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/gab@chromium.org/137383011/80001
6 years, 10 months ago (2014-01-30 17:16:02 UTC) #10
commit-bot: I haz the power
Change committed as 248032
6 years, 10 months ago (2014-01-30 21:15:52 UTC) #11
commit-bot: I haz the power
6 years, 10 months ago (2014-01-30 21:15:55 UTC) #12
Message was sent while issue was closed.
CQ bit was unchecked on CL. Ignoring.

Powered by Google App Engine
This is Rietveld 408576698