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

Unified Diff: device/usb/usb_device_handle_unittest.cc

Issue 543893002: Random fixes through Chrome for scoped_reftpr T* removal. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 3 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/usb/usb_device_handle_unittest.cc
diff --git a/device/usb/usb_device_handle_unittest.cc b/device/usb/usb_device_handle_unittest.cc
index f24f21010ccfe49a86aa2e4877dac614eebcc7e9..98523b9d55c2e52cf2d0e7e2a1f1afcc65b49ee5 100644
--- a/device/usb/usb_device_handle_unittest.cc
+++ b/device/usb/usb_device_handle_unittest.cc
@@ -30,11 +30,11 @@ class UsbDeviceHandleTest : public ::testing::Test {
ASSERT_TRUE(gadget_->SetType(UsbTestGadget::ECHO));
handle_ = gadget_->GetDevice()->Open();
- ASSERT_TRUE(handle_);
+ ASSERT_TRUE(handle_.get());
}
virtual void TearDown() {
- if (handle_) {
+ if (handle_.get()) {
handle_->Close();
}
gadget_.reset(NULL);
@@ -77,7 +77,7 @@ class TestCompletionCallback {
};
TEST_F(UsbDeviceHandleTest, InterruptTransfer) {
- if (!handle_) {
+ if (!handle_.get()) {
return;
}
@@ -85,7 +85,7 @@ TEST_F(UsbDeviceHandleTest, InterruptTransfer) {
TestCompletionCallback in_completion;
handle_->InterruptTransfer(USB_DIRECTION_INBOUND,
0x81,
- in_buffer,
+ in_buffer.get(),
in_buffer->size(),
5000, // 5 second timeout
in_completion.callback());
@@ -99,7 +99,7 @@ TEST_F(UsbDeviceHandleTest, InterruptTransfer) {
handle_->InterruptTransfer(USB_DIRECTION_OUTBOUND,
0x01,
- out_buffer,
+ out_buffer.get(),
out_buffer->size(),
5000, // 5 second timeout
out_completion.callback());
@@ -118,7 +118,7 @@ TEST_F(UsbDeviceHandleTest, InterruptTransfer) {
}
TEST_F(UsbDeviceHandleTest, BulkTransfer) {
- if (!handle_) {
+ if (!handle_.get()) {
return;
}
@@ -127,7 +127,7 @@ TEST_F(UsbDeviceHandleTest, BulkTransfer) {
TestCompletionCallback in_completion;
handle_->BulkTransfer(USB_DIRECTION_INBOUND,
0x81,
- in_buffer,
+ in_buffer.get(),
in_buffer->size(),
5000, // 5 second timeout
in_completion.callback());
@@ -141,7 +141,7 @@ TEST_F(UsbDeviceHandleTest, BulkTransfer) {
handle_->BulkTransfer(USB_DIRECTION_OUTBOUND,
0x01,
- out_buffer,
+ out_buffer.get(),
out_buffer->size(),
5000, // 5 second timeout
out_completion.callback());
« no previous file with comments | « components/variations/variations_seed_processor.cc ('k') | gpu/command_buffer/service/in_process_command_buffer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698