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

Side by Side Diff: chrome/browser/sync/glue/android_invalidator_bridge_proxy_unittest.cc

Issue 14113053: chrome: Use base::MessageLoop. (Part 3) (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase again Created 7 years, 6 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/sync/glue/android_invalidator_bridge_proxy.h" 5 #include "chrome/browser/sync/glue/android_invalidator_bridge_proxy.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "base/threading/thread.h" 10 #include "base/threading/thread.h"
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
51 return invalidator_.get(); 51 return invalidator_.get();
52 } 52 }
53 53
54 protected: 54 protected:
55 void DestroyInvalidator() { 55 void DestroyInvalidator() {
56 invalidator_.reset(); 56 invalidator_.reset();
57 bridge_.StopForShutdown(); 57 bridge_.StopForShutdown();
58 ui_loop_.RunUntilIdle(); 58 ui_loop_.RunUntilIdle();
59 } 59 }
60 60
61 MessageLoop ui_loop_; 61 base::MessageLoop ui_loop_;
62 content::TestBrowserThread ui_thread_; 62 content::TestBrowserThread ui_thread_;
63 ::testing::NiceMock<ProfileMock> mock_profile_; 63 ::testing::NiceMock<ProfileMock> mock_profile_;
64 AndroidInvalidatorBridge bridge_; 64 AndroidInvalidatorBridge bridge_;
65 scoped_ptr<AndroidInvalidatorBridgeProxy> invalidator_; 65 scoped_ptr<AndroidInvalidatorBridgeProxy> invalidator_;
66 }; 66 };
67 67
68 TEST_F(AndroidInvalidatorBridgeProxyTest, HandlerMethods) { 68 TEST_F(AndroidInvalidatorBridgeProxyTest, HandlerMethods) {
69 syncer::ObjectIdSet ids; 69 syncer::ObjectIdSet ids;
70 ids.insert(invalidation::ObjectId(1, "id1")); 70 ids.insert(invalidation::ObjectId(1, "id1"));
71 71
(...skipping 13 matching lines...) Expand all
85 // The AndroidInvalidatorBridge never enters an error state. 85 // The AndroidInvalidatorBridge never enters an error state.
86 EXPECT_EQ(syncer::INVALIDATIONS_ENABLED, 86 EXPECT_EQ(syncer::INVALIDATIONS_ENABLED,
87 GetInvalidator()->GetInvalidatorState()); 87 GetInvalidator()->GetInvalidatorState());
88 EXPECT_EQ(syncer::INVALIDATIONS_ENABLED, 88 EXPECT_EQ(syncer::INVALIDATIONS_ENABLED,
89 GetBridge()->GetInvalidatorState()); 89 GetBridge()->GetInvalidatorState());
90 } 90 }
91 91
92 } // namespace 92 } // namespace
93 } // namespace browser_sync 93 } // namespace browser_sync
94 94
OLDNEW
« no previous file with comments | « chrome/browser/sync/backend_migrator_unittest.cc ('k') | chrome/browser/sync/glue/android_invalidator_bridge_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698