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

Issue 852593002: Allow overriding GoogleLocationSettingsHelper for tests. (Closed)

Created:
5 years, 11 months ago by newt (away)
Modified:
5 years, 11 months ago
CC:
chromium-reviews, mlamouri+watch-geolocation_chromium.org, Michael van Ouwerkerk
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Allow overriding GoogleLocationSettingsHelper for tests. Previously, GoogleLocationSettingsHelper could be "overridden" only by compiling in a different implementation of the static method GoogleLocationSettingsHelper::Create(). This complicates the build targets (since the default implementation of Create() can't be defined in shared code, since test code needs a different implementation), and complicates the process of upstreaming the internal implementation of GoogleLocationSettingsHelper. This CL keeps the static method, but adds a new method for overriding the GoogleLocationSettingsHelper: GeolocationPermissionContextAndroid::SetGoogleLocationSettingsHelperForTests(). In a later CL, the static method will be removed. BUG=448400 Committed: https://crrev.com/ad75c73e7b29abf6f3e06ba71ea6a63140e430e6 Cr-Commit-Position: refs/heads/master@{#311317}

Patch Set 1 #

Total comments: 6

Patch Set 2 : addressed comments #

Unified diffs Side-by-side diffs Delta from patch set Stats (+32 lines, -9 lines) Patch
M chrome/browser/android/google_location_settings_helper.h View 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/android/mock_google_location_settings_helper.h View 1 1 chunk +4 lines, -5 lines 0 comments Download
M chrome/browser/geolocation/geolocation_permission_context_android.h View 1 4 chunks +13 lines, -2 lines 0 comments Download
M chrome/browser/geolocation/geolocation_permission_context_android.cc View 1 1 chunk +6 lines, -0 lines 0 comments Download
M chrome/browser/geolocation/geolocation_permission_context_unittest.cc View 1 2 chunks +8 lines, -2 lines 0 comments Download

Messages

Total messages: 13 (3 generated)
newt (away)
PTAL
5 years, 11 months ago (2015-01-13 16:26:06 UTC) #2
Michael van Ouwerkerk
https://codereview.chromium.org/852593002/diff/1/chrome/browser/android/mock_google_location_settings_helper.h File chrome/browser/android/mock_google_location_settings_helper.h (right): https://codereview.chromium.org/852593002/diff/1/chrome/browser/android/mock_google_location_settings_helper.h#newcode14 chrome/browser/android/mock_google_location_settings_helper.h:14: virtual ~MockGoogleLocationSettingsHelper(); Nit: use override rather than virtual. https://codereview.chromium.org/852593002/diff/1/chrome/browser/geolocation/geolocation_permission_context_android.h ...
5 years, 11 months ago (2015-01-13 16:33:48 UTC) #3
newt (away)
https://codereview.chromium.org/852593002/diff/1/chrome/browser/android/mock_google_location_settings_helper.h File chrome/browser/android/mock_google_location_settings_helper.h (right): https://codereview.chromium.org/852593002/diff/1/chrome/browser/android/mock_google_location_settings_helper.h#newcode14 chrome/browser/android/mock_google_location_settings_helper.h:14: virtual ~MockGoogleLocationSettingsHelper(); On 2015/01/13 16:33:47, Michael van Ouwerkerk wrote: ...
5 years, 11 months ago (2015-01-13 16:55:04 UTC) #4
Michael van Ouwerkerk
lgtm
5 years, 11 months ago (2015-01-13 17:00:55 UTC) #5
newt (away)
+dtrainor for chrome/browser/android OWNERS
5 years, 11 months ago (2015-01-13 17:03:04 UTC) #7
newt (away)
Thanks, Michael!
5 years, 11 months ago (2015-01-13 17:03:15 UTC) #8
David Trainor- moved to gerrit
chrome/browser/android lgtm
5 years, 11 months ago (2015-01-13 18:37:12 UTC) #9
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/852593002/20001
5 years, 11 months ago (2015-01-13 18:39:24 UTC) #11
commit-bot: I haz the power
Committed patchset #2 (id:20001)
5 years, 11 months ago (2015-01-13 20:22:06 UTC) #12
commit-bot: I haz the power
5 years, 11 months ago (2015-01-13 20:22:57 UTC) #13
Message was sent while issue was closed.
Patchset 2 (id:??) landed as
https://crrev.com/ad75c73e7b29abf6f3e06ba71ea6a63140e430e6
Cr-Commit-Position: refs/heads/master@{#311317}

Powered by Google App Engine
This is Rietveld 408576698