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

Side by Side Diff: remoting/protocol/buffered_socket_writer_unittest.cc

Issue 628753002: replace OVERRIDE and FINAL with override and final in remoting/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase on master Created 6 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 unified diff | Download patch
« no previous file with comments | « remoting/protocol/buffered_socket_writer.h ('k') | remoting/protocol/channel_multiplexer.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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "remoting/protocol/buffered_socket_writer.h" 5 #include "remoting/protocol/buffered_socket_writer.h"
6 6
7 #include <stdlib.h> 7 #include <stdlib.h>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/message_loop/message_loop.h" 10 #include "base/message_loop/message_loop.h"
(...skipping 29 matching lines...) Expand all
40 socket_.reset(); 40 socket_.reset();
41 base::MessageLoop::current()->PostTask(FROM_HERE, 41 base::MessageLoop::current()->PostTask(FROM_HERE,
42 base::MessageLoop::QuitClosure()); 42 base::MessageLoop::QuitClosure());
43 } 43 }
44 44
45 void Unexpected() { 45 void Unexpected() {
46 EXPECT_TRUE(false); 46 EXPECT_TRUE(false);
47 } 47 }
48 48
49 protected: 49 protected:
50 virtual void SetUp() OVERRIDE { 50 virtual void SetUp() override {
51 socket_.reset(new FakeStreamSocket()); 51 socket_.reset(new FakeStreamSocket());
52 writer_.reset(new BufferedSocketWriter()); 52 writer_.reset(new BufferedSocketWriter());
53 writer_->Init(socket_.get(), base::Bind( 53 writer_->Init(socket_.get(), base::Bind(
54 &BufferedSocketWriterTest::OnWriteFailed, base::Unretained(this))); 54 &BufferedSocketWriterTest::OnWriteFailed, base::Unretained(this)));
55 test_buffer_ = new net::IOBufferWithSize(kTestBufferSize); 55 test_buffer_ = new net::IOBufferWithSize(kTestBufferSize);
56 test_buffer_2_ = new net::IOBufferWithSize(kTestBufferSize); 56 test_buffer_2_ = new net::IOBufferWithSize(kTestBufferSize);
57 for (int i = 0; i< kTestBufferSize; ++i) { 57 for (int i = 0; i< kTestBufferSize; ++i) {
58 test_buffer_->data()[i] = rand() % 256; 58 test_buffer_->data()[i] = rand() % 256;
59 test_buffer_2_->data()[i] = rand() % 256; 59 test_buffer_2_->data()[i] = rand() % 256;
60 } 60 }
(...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after
180 socket_->set_next_write_error(net::ERR_FAILED); 180 socket_->set_next_write_error(net::ERR_FAILED);
181 base::RunLoop().RunUntilIdle(); 181 base::RunLoop().RunUntilIdle();
182 EXPECT_EQ(net::ERR_FAILED, write_error_); 182 EXPECT_EQ(net::ERR_FAILED, write_error_);
183 EXPECT_EQ(static_cast<size_t>(test_buffer_->size()), 183 EXPECT_EQ(static_cast<size_t>(test_buffer_->size()),
184 socket_->written_data().size()); 184 socket_->written_data().size());
185 } 185 }
186 186
187 } // namespace protocol 187 } // namespace protocol
188 } // namespace remoting 188 } // namespace remoting
189 189
OLDNEW
« no previous file with comments | « remoting/protocol/buffered_socket_writer.h ('k') | remoting/protocol/channel_multiplexer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698