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

Side by Side Diff: device/serial/data_source_unittest.cc

Issue 1410053006: Move third_party/mojo/src/mojo/public to mojo/public (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: merge Created 5 years, 1 month 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
« no previous file with comments | « device/serial/data_source_sender.h ('k') | device/serial/serial_connection.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "base/bind.h" 5 #include "base/bind.h"
6 #include "base/message_loop/message_loop.h" 6 #include "base/message_loop/message_loop.h"
7 #include "base/run_loop.h" 7 #include "base/run_loop.h"
8 #include "base/strings/string_piece.h" 8 #include "base/strings/string_piece.h"
9 #include "device/serial/buffer.h" 9 #include "device/serial/buffer.h"
10 #include "device/serial/data_receiver.h" 10 #include "device/serial/data_receiver.h"
11 #include "device/serial/data_source_sender.h" 11 #include "device/serial/data_source_sender.h"
12 #include "device/serial/data_stream.mojom.h" 12 #include "device/serial/data_stream.mojom.h"
13 #include "mojo/public/cpp/bindings/interface_ptr.h"
14 #include "mojo/public/cpp/environment/async_waiter.h"
13 #include "testing/gtest/include/gtest/gtest.h" 15 #include "testing/gtest/include/gtest/gtest.h"
14 #include "third_party/mojo/src/mojo/public/cpp/bindings/interface_ptr.h"
15 #include "third_party/mojo/src/mojo/public/cpp/environment/async_waiter.h"
16 16
17 namespace device { 17 namespace device {
18 18
19 class DataSourceTest : public testing::Test { 19 class DataSourceTest : public testing::Test {
20 public: 20 public:
21 enum Event { 21 enum Event {
22 EVENT_NONE, 22 EVENT_NONE,
23 EVENT_WRITE_BUFFER_READY, 23 EVENT_WRITE_BUFFER_READY,
24 EVENT_RECEIVE_COMPLETE, 24 EVENT_RECEIVE_COMPLETE,
25 EVENT_ERROR, 25 EVENT_ERROR,
(...skipping 223 matching lines...) Expand 10 before | Expand all | Expand 10 after
249 // Test that the receiver shutting down is correctly reported to the source. 249 // Test that the receiver shutting down is correctly reported to the source.
250 TEST_F(DataSourceTest, ReceiverShutdown) { 250 TEST_F(DataSourceTest, ReceiverShutdown) {
251 Receive(); 251 Receive();
252 receiver_ = NULL; 252 receiver_ = NULL;
253 EXPECT_EQ(kFatalError, error_); 253 EXPECT_EQ(kFatalError, error_);
254 WaitForEvent(EVENT_ERROR); 254 WaitForEvent(EVENT_ERROR);
255 EXPECT_TRUE(seen_connection_error_); 255 EXPECT_TRUE(seen_connection_error_);
256 } 256 }
257 257
258 } // namespace device 258 } // namespace device
OLDNEW
« no previous file with comments | « device/serial/data_source_sender.h ('k') | device/serial/serial_connection.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698