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

Unified Diff: device/serial/serial_connection_unittest.cc

Issue 873293006: Revert of Remove Client= from device/serial/data_stream.mojom. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 10 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
« no previous file with comments | « device/serial/serial_connection_factory.cc ('k') | device/serial/serial_service_impl.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: device/serial/serial_connection_unittest.cc
diff --git a/device/serial/serial_connection_unittest.cc b/device/serial/serial_connection_unittest.cc
index 53d530329871bc58b03fecaf3c61184511a0c397..151ed77dfcbbb7ebd2f48d8caf7334699a849692 100644
--- a/device/serial/serial_connection_unittest.cc
+++ b/device/serial/serial_connection_unittest.cc
@@ -74,23 +74,17 @@
scoped_ptr<SerialDeviceEnumerator>(new FakeSerialDeviceEnumerator)),
&service);
service.set_error_handler(this);
- mojo::InterfacePtr<serial::DataSink> sink;
- mojo::InterfacePtr<serial::DataSinkClient> sink_client;
- mojo::InterfaceRequest<serial::DataSinkClient> sink_client_request =
- mojo::GetProxy(&sink_client);
- mojo::InterfacePtr<serial::DataSource> source;
- mojo::InterfacePtr<serial::DataSourceClient> source_client;
- mojo::InterfaceRequest<serial::DataSourceClient> source_client_request =
- mojo::GetProxy(&source_client);
- service->Connect("device", serial::ConnectionOptions::New(),
- mojo::GetProxy(&connection_), mojo::GetProxy(&sink),
- sink_client.Pass(), mojo::GetProxy(&source),
- source_client.Pass());
- sender_.reset(new DataSender(sink.Pass(), sink_client_request.Pass(),
- kBufferSize, serial::SEND_ERROR_DISCONNECTED));
- receiver_ =
- new DataReceiver(source.Pass(), source_client_request.Pass(),
- kBufferSize, serial::RECEIVE_ERROR_DISCONNECTED);
+ mojo::InterfacePtr<serial::DataSink> consumer;
+ mojo::InterfacePtr<serial::DataSource> producer;
+ service->Connect("device",
+ serial::ConnectionOptions::New(),
+ mojo::GetProxy(&connection_),
+ mojo::GetProxy(&consumer),
+ mojo::GetProxy(&producer));
+ sender_.reset(new DataSender(
+ consumer.Pass(), kBufferSize, serial::SEND_ERROR_DISCONNECTED));
+ receiver_ = new DataReceiver(
+ producer.Pass(), kBufferSize, serial::RECEIVE_ERROR_DISCONNECTED);
connection_.set_error_handler(this);
connection_->GetInfo(
base::Bind(&SerialConnectionTest::StoreInfo, base::Unretained(this)));
« no previous file with comments | « device/serial/serial_connection_factory.cc ('k') | device/serial/serial_service_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698