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

Unified Diff: components/invalidation/sync_invalidation_listener_unittest.cc

Issue 446223002: Remove WeakHandle from components/invalidation (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Hack to fix GN Created 6 years, 4 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: components/invalidation/sync_invalidation_listener_unittest.cc
diff --git a/components/invalidation/sync_invalidation_listener_unittest.cc b/components/invalidation/sync_invalidation_listener_unittest.cc
index 339511e608e1c4910a0e9d6b3b6f9b6f139db95a..141dec5f44f3738fe8ebd8c58638c9188e76e877 100644
--- a/components/invalidation/sync_invalidation_listener_unittest.cc
+++ b/components/invalidation/sync_invalidation_listener_unittest.cc
@@ -20,7 +20,6 @@
#include "google/cacheinvalidation/include/invalidation-client.h"
#include "google/cacheinvalidation/include/types.h"
#include "jingle/notifier/listener/fake_push_client.h"
-#include "sync/internal_api/public/util/weak_handle.h"
#include "testing/gtest/include/gtest/gtest.h"
namespace syncer {
@@ -292,12 +291,15 @@ class SyncInvalidationListenerTest : public testing::Test {
void StartClient() {
fake_invalidation_client_ = NULL;
- listener_.Start(base::Bind(&CreateFakeInvalidationClient,
- &fake_invalidation_client_),
- kClientId, kClientInfo, kState,
- fake_tracker_.GetSavedInvalidations(),
- MakeWeakHandle(fake_tracker_.AsWeakPtr()),
- &fake_delegate_);
+ listener_.Start(
+ base::Bind(&CreateFakeInvalidationClient, &fake_invalidation_client_),
+ kClientId,
+ kClientInfo,
+ kState,
+ fake_tracker_.GetSavedInvalidations(),
+ fake_tracker_.AsWeakPtr(),
+ base::MessageLoopProxy::current(),
+ &fake_delegate_);
DCHECK(fake_invalidation_client_);
}
@@ -376,7 +378,10 @@ class SyncInvalidationListenerTest : public testing::Test {
return SingleObjectInvalidationSet();
}
ObjectIdInvalidationMap map;
- it->second.ExportInvalidations(WeakHandle<AckHandler>(), &map);
+ it->second.ExportInvalidations(
+ base::WeakPtr<AckHandler>(),
+ scoped_refptr<base::SingleThreadTaskRunner>(),
pavely 2014/08/08 20:08:30 Most of places with Post don't check task_runner.
rlarocque 2014/08/08 21:19:35 The task runner will be used by a bunch of Invalid
+ &map);
if (map.Empty()) {
return SingleObjectInvalidationSet();
} else {

Powered by Google App Engine
This is Rietveld 408576698