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

Unified Diff: content/browser/service_worker/service_worker_storage_unittest.cc

Issue 2181553003: Stop passing const-reference of SWRegistration in all GetRegistrationsCallbacks. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: use std::move Created 4 years, 5 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 side-by-side diff with in-line comments
Download patch
Index: content/browser/service_worker/service_worker_storage_unittest.cc
diff --git a/content/browser/service_worker/service_worker_storage_unittest.cc b/content/browser/service_worker/service_worker_storage_unittest.cc
index 478ace71d8340575aad4b28ee9ceb9ec3acd31c3..7daa354cd8208140a2be6826dc1d6863eadc61ef 100644
--- a/content/browser/service_worker/service_worker_storage_unittest.cc
+++ b/content/browser/service_worker/service_worker_storage_unittest.cc
@@ -62,12 +62,11 @@ ServiceWorkerStorage::StatusCallback MakeStatusCallback(
return base::Bind(&StatusCallback, was_called, result);
}
-void FindCallback(
- bool* was_called,
- ServiceWorkerStatusCode* result,
- scoped_refptr<ServiceWorkerRegistration>* found,
- ServiceWorkerStatusCode status,
- const scoped_refptr<ServiceWorkerRegistration>& registration) {
+void FindCallback(bool* was_called,
+ ServiceWorkerStatusCode* result,
+ scoped_refptr<ServiceWorkerRegistration>* found,
+ ServiceWorkerStatusCode status,
+ scoped_refptr<ServiceWorkerRegistration> registration) {
*was_called = true;
*result = status;
*found = registration;
nhiroki 2016/07/25 09:15:40 std::move
horo 2016/07/25 09:32:01 Done.
@@ -434,7 +433,7 @@ class ServiceWorkerStorageTest : public testing::Test {
}
ServiceWorkerStatusCode UpdateToActiveState(
- const scoped_refptr<ServiceWorkerRegistration>& registration) {
+ scoped_refptr<ServiceWorkerRegistration> registration) {
bool was_called = false;
ServiceWorkerStatusCode result = SERVICE_WORKER_ERROR_MAX_VALUE;
storage()->UpdateToActiveState(registration.get(),
@@ -446,7 +445,7 @@ class ServiceWorkerStorageTest : public testing::Test {
}
void UpdateLastUpdateCheckTime(
- const scoped_refptr<ServiceWorkerRegistration>& registration) {
+ scoped_refptr<ServiceWorkerRegistration> registration) {
storage()->UpdateLastUpdateCheckTime(registration.get());
base::RunLoop().RunUntilIdle();
}

Powered by Google App Engine
This is Rietveld 408576698