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

Side by Side Diff: mojo/public/cpp/bindings/tests/binding_callback_unittest.cc

Issue 2104363004: Remove remaining calls to deprecated MessageLoop methods. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: CR gab 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 unified diff | Download patch
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 <stdint.h> 5 #include <stdint.h>
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/callback.h" 8 #include "base/callback.h"
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/message_loop/message_loop.h" 10 #include "base/message_loop/message_loop.h"
(...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after
122 122
123 class BindingCallbackTest : public testing::Test { 123 class BindingCallbackTest : public testing::Test {
124 public: 124 public:
125 BindingCallbackTest() {} 125 BindingCallbackTest() {}
126 ~BindingCallbackTest() override {} 126 ~BindingCallbackTest() override {}
127 127
128 protected: 128 protected:
129 int32_t last_client_callback_value_seen_; 129 int32_t last_client_callback_value_seen_;
130 sample::ProviderPtr interface_ptr_; 130 sample::ProviderPtr interface_ptr_;
131 131
132 void PumpMessages() { loop_.RunUntilIdle(); } 132 void PumpMessages() { base::RunLoop().RunUntilIdle(); }
133 133
134 private: 134 private:
135 base::MessageLoop loop_; 135 base::MessageLoop loop_;
136 }; 136 };
137 137
138 // Tests that the InterfacePtr and the Binding can communicate with each 138 // Tests that the InterfacePtr and the Binding can communicate with each
139 // other normally. 139 // other normally.
140 TEST_F(BindingCallbackTest, Basic) { 140 TEST_F(BindingCallbackTest, Basic) {
141 // Create the ServerImpl and the Binding. 141 // Create the ServerImpl and the Binding.
142 InterfaceImpl server_impl; 142 InterfaceImpl server_impl;
(...skipping 194 matching lines...) Expand 10 before | Expand all | Expand 10 after
337 regex.clear(); 337 regex.clear();
338 #endif // OS_WIN 338 #endif // OS_WIN
339 EXPECT_DEATH_IF_SUPPORTED(server_impl.DeleteCallback(), regex.c_str()); 339 EXPECT_DEATH_IF_SUPPORTED(server_impl.DeleteCallback(), regex.c_str());
340 #endif // (!defined(NDEBUG) || defined(DCHECK_ALWAYS_ON)) && 340 #endif // (!defined(NDEBUG) || defined(DCHECK_ALWAYS_ON)) &&
341 // !defined(OS_ANDROID) 341 // !defined(OS_ANDROID)
342 } 342 }
343 343
344 } // namespace 344 } // namespace
345 } // namespace test 345 } // namespace test
346 } // namespace mojo 346 } // namespace mojo
OLDNEW
« no previous file with comments | « mojo/public/cpp/bindings/tests/associated_interface_unittest.cc ('k') | mojo/public/cpp/bindings/tests/binding_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698