AW UMA: refactor package name sampling
This moves the package name sampling result into a boolean member variable (which slightly improves performance, and is more consistent with is_in_sample_), and rephrases a comment. This fixes some tests to mock the IsInPackageNameSample() value prior to MaybeStartMetrics, rather than after, since the value is cached during that method. This is a follow up to feedback on https://crrev.com/c/1898711. Test: run_android_webview_unittests --gtest_filter=AwMetricsServiceClientTest.* Change-Id: I824540aa7362ab34f9cb4981b88cc446338bdff3 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1937704Reviewed-by:Tao Bai <michaelbai@chromium.org> Commit-Queue: Nate Fischer <ntfschr@chromium.org> Cr-Commit-Position: refs/heads/master@{#719429}
Showing
Please register or sign in to comment