OLD | NEW |
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 #ifndef NET_SPDY_TEST_UTILS_H_ | 5 #ifndef NET_SPDY_TEST_UTILS_H_ |
6 #define NET_SPDY_TEST_UTILS_H_ | 6 #define NET_SPDY_TEST_UTILS_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "net/spdy/spdy_protocol.h" | 10 #include "net/spdy/spdy_protocol.h" |
11 | 11 |
12 namespace net { | 12 namespace net { |
13 | 13 |
14 namespace test { | 14 namespace test { |
15 | 15 |
16 std::string HexDumpWithMarks(const unsigned char* data, int length, | 16 std::string HexDumpWithMarks(const unsigned char* data, |
17 const bool* marks, int mark_length); | 17 int length, |
| 18 const bool* marks, |
| 19 int mark_length); |
18 | 20 |
19 void CompareCharArraysWithHexError( | 21 void CompareCharArraysWithHexError(const std::string& description, |
20 const std::string& description, | 22 const unsigned char* actual, |
21 const unsigned char* actual, | 23 const int actual_len, |
22 const int actual_len, | 24 const unsigned char* expected, |
23 const unsigned char* expected, | 25 const int expected_len); |
24 const int expected_len); | |
25 | 26 |
26 void SetFrameFlags(SpdyFrame* frame, | 27 void SetFrameFlags(SpdyFrame* frame, |
27 uint8 flags, | 28 uint8 flags, |
28 SpdyMajorVersion spdy_version); | 29 SpdyMajorVersion spdy_version); |
29 | 30 |
30 void SetFrameLength(SpdyFrame* frame, | 31 void SetFrameLength(SpdyFrame* frame, |
31 size_t length, | 32 size_t length, |
32 SpdyMajorVersion spdy_version); | 33 SpdyMajorVersion spdy_version); |
33 | 34 |
34 } // namespace test | 35 } // namespace test |
35 | 36 |
36 } // namespace net | 37 } // namespace net |
37 | 38 |
38 #endif // NET_SPDY_TEST_UTILS_H_ | 39 #endif // NET_SPDY_TEST_UTILS_H_ |
OLD | NEW |