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

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

Issue 4779001: Added CompoundBuffer that will be used to store data in the encoding/decoding (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: - Created 10 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 | Annotate | Revision Log
« no previous file with comments | « remoting/protocol/message_decoder.cc ('k') | remoting/protocol/message_reader.cc » ('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) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 <string> 5 #include <string>
6 6
7 #include "base/scoped_ptr.h" 7 #include "base/scoped_ptr.h"
8 #include "base/stl_util-inl.h" 8 #include "base/stl_util-inl.h"
9 #include "net/base/io_buffer.h"
10 #include "remoting/base/multiple_array_input_stream.h"
11 #include "remoting/proto/internal.pb.h" 9 #include "remoting/proto/internal.pb.h"
12 #include "remoting/protocol/message_decoder.h" 10 #include "remoting/protocol/message_decoder.h"
13 #include "remoting/protocol/util.h" 11 #include "remoting/protocol/util.h"
14 #include "testing/gtest/include/gtest/gtest.h" 12 #include "testing/gtest/include/gtest/gtest.h"
15 13
16 namespace remoting { 14 namespace remoting {
17 15
18 static const int kTestKey = 142; 16 static const int kTestKey = 142;
19 17
20 static void AppendMessage(const ChromotingClientMessage& msg, 18 static void AppendMessage(const ChromotingClientMessage& msg,
(...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after
101 const int kReads[] = {50, 50, 5}; 99 const int kReads[] = {50, 50, 5};
102 SimulateReadSequence(kReads, arraysize(kReads)); 100 SimulateReadSequence(kReads, arraysize(kReads));
103 } 101 }
104 102
105 TEST(MessageDecoderTest, EmptyReads) { 103 TEST(MessageDecoderTest, EmptyReads) {
106 const int kReads[] = {4, 0, 50, 0}; 104 const int kReads[] = {4, 0, 50, 0};
107 SimulateReadSequence(kReads, arraysize(kReads)); 105 SimulateReadSequence(kReads, arraysize(kReads));
108 } 106 }
109 107
110 } // namespace remoting 108 } // namespace remoting
OLDNEW
« no previous file with comments | « remoting/protocol/message_decoder.cc ('k') | remoting/protocol/message_reader.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698