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

Unified Diff: device/bluetooth/bluetooth_socket_chromeos_unittest.cc

Issue 1396083003: Don't use base::MessageLoop::{Quit,QuitClosure} in ash/, chromeos/, device/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 2 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: device/bluetooth/bluetooth_socket_chromeos_unittest.cc
diff --git a/device/bluetooth/bluetooth_socket_chromeos_unittest.cc b/device/bluetooth/bluetooth_socket_chromeos_unittest.cc
index 747b8572ce9a7b413b479b34319040159bf532d1..477f3a7c174823d1c13ffef26a6b2294c0fc74b5 100644
--- a/device/bluetooth/bluetooth_socket_chromeos_unittest.cc
+++ b/device/bluetooth/bluetooth_socket_chromeos_unittest.cc
@@ -100,7 +100,7 @@ class BluetoothSocketChromeOSTest : public testing::Test {
void SuccessCallback() {
++success_callback_count_;
- message_loop_.Quit();
+ message_loop_.QuitWhenIdle();
}
void ErrorCallback(const std::string& message) {
@@ -108,21 +108,21 @@ class BluetoothSocketChromeOSTest : public testing::Test {
last_message_ = message;
if (message_loop_.is_running())
- message_loop_.Quit();
+ message_loop_.QuitWhenIdle();
}
void ConnectToServiceSuccessCallback(scoped_refptr<BluetoothSocket> socket) {
++success_callback_count_;
last_socket_ = socket;
- message_loop_.Quit();
+ message_loop_.QuitWhenIdle();
}
void SendSuccessCallback(int bytes_sent) {
++success_callback_count_;
last_bytes_sent_ = bytes_sent;
- message_loop_.Quit();
+ message_loop_.QuitWhenIdle();
}
void ReceiveSuccessCallback(int bytes_received,
@@ -131,7 +131,7 @@ class BluetoothSocketChromeOSTest : public testing::Test {
last_bytes_received_ = bytes_received;
last_io_buffer_ = io_buffer;
- message_loop_.Quit();
+ message_loop_.QuitWhenIdle();
}
void ReceiveErrorCallback(BluetoothSocket::ErrorReason reason,
@@ -140,7 +140,7 @@ class BluetoothSocketChromeOSTest : public testing::Test {
last_reason_ = reason;
last_message_ = error_message;
- message_loop_.Quit();
+ message_loop_.QuitWhenIdle();
}
void CreateServiceSuccessCallback(scoped_refptr<BluetoothSocket> socket) {
@@ -148,7 +148,7 @@ class BluetoothSocketChromeOSTest : public testing::Test {
last_socket_ = socket;
if (message_loop_.is_running())
- message_loop_.Quit();
+ message_loop_.QuitWhenIdle();
}
void AcceptSuccessCallback(const BluetoothDevice* device,
@@ -157,7 +157,7 @@ class BluetoothSocketChromeOSTest : public testing::Test {
last_device_ = device;
last_socket_ = socket;
- message_loop_.Quit();
+ message_loop_.QuitWhenIdle();
}
void ImmediateSuccessCallback() {
« no previous file with comments | « device/bluetooth/bluetooth_gatt_chromeos_unittest.cc ('k') | device/bluetooth/test/test_bluetooth_adapter_observer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698