/external/chromium_org/net/url_request/ |
D | url_request_ftp_job_unittest.cc | 231 void AddSocket(MockRead* reads, size_t reads_size, in AddSocket() 263 MockRead reads[] = { in TEST_F() 264 MockRead(ASYNC, 1, "HTTP/1.1 200 OK\r\n"), in TEST_F() 265 MockRead(ASYNC, 2, "Content-Length: 9\r\n\r\n"), in TEST_F() 266 MockRead(ASYNC, 3, "test.html"), in TEST_F() 313 MockRead reads[] = { in TEST_F() 315 MockRead(ASYNC, 1, "HTTP/1.1 407 Proxy Authentication Required\r\n"), in TEST_F() 316 MockRead(ASYNC, 2, "Proxy-Authenticate: Basic " in TEST_F() 318 MockRead(ASYNC, 3, "Content-Length: 9\r\n\r\n"), in TEST_F() 319 MockRead(ASYNC, 4, "test.html"), in TEST_F() [all …]
|
/external/chromium_org/net/quic/ |
D | quic_network_transaction_unittest.cc | 73 reads_.push_back(MockRead(SYNCHRONOUS, packet->data(), packet->length(), in AddRead() 79 reads_.push_back(MockRead(mode, rv)); in AddRead() 90 MockRead* reads = reads_.empty() ? NULL : &reads_[0]; in AddDelayedSocketDataToFactory() 100 std::vector<MockRead> reads_; 441 MockRead http_reads[] = { in TEST_P() 442 MockRead("HTTP/1.1 200 OK\r\n\r\n"), in TEST_P() 443 MockRead("hello world"), in TEST_P() 444 MockRead(SYNCHRONOUS, ERR_TEST_PEER_CLOSE_AFTER_NEXT_MOCK_READ), in TEST_P() 445 MockRead(ASYNC, OK) in TEST_P() 459 MockRead http_reads[] = { in TEST_P() [all …]
|
D | quic_stream_factory_test.cc | 149 MockRead reads[] = { in GetSourcePortForNewSessionInner() 150 MockRead(ASYNC, OK, 0) // EOF in GetSourcePortForNewSessionInner() 226 MockRead reads[] = { in TEST_P() 227 MockRead(ASYNC, OK, 0) // EOF in TEST_P() 268 MockRead reads[] = { in TEST_P() 269 MockRead(ASYNC, OK, 0) // EOF in TEST_P() 297 MockRead reads[] = { in TEST_P() 298 MockRead(ASYNC, OK, 0) // EOF in TEST_P() 332 MockRead reads[] = { in TEST_P() 333 MockRead(ASYNC, OK, 0) // EOF in TEST_P() [all …]
|
/external/chromium_org/net/socket/ |
D | deterministic_socket_data_unittest.cc | 38 void Initialize(MockRead* reads, size_t reads_count, MockWrite* writes, 89 void DeterministicSocketDataTest::Initialize(MockRead* reads, in Initialize() 199 MockRead reads[] = { in TEST_F() 200 MockRead(SYNCHRONOUS, kMsg1, kLen1, 0), // Sync Read in TEST_F() 201 MockRead(SYNCHRONOUS, 0, 1), // EOF in TEST_F() 211 MockRead reads[] = { in TEST_F() 212 MockRead(SYNCHRONOUS, kMsg1, kLen1, 1), // Sync Read in TEST_F() 213 MockRead(SYNCHRONOUS, 0, 2), // EOF in TEST_F() 228 MockRead reads[] = { in TEST_F() 229 MockRead(SYNCHRONOUS, kMsg1, kLen1, 0), // Sync Read in TEST_F() [all …]
|
D | socks5_client_socket_unittest.cc | 35 scoped_ptr<SOCKS5ClientSocket> BuildMockSocket(MockRead reads[], 85 MockRead reads[], in BuildMockSocket() 132 MockRead data_reads[] = { in TEST_F() 133 MockRead(ASYNC, kSOCKS5GreetResponse, kSOCKS5GreetResponseLength), in TEST_F() 134 MockRead(ASYNC, kSOCKS5OkResponse, kSOCKS5OkResponseLength), in TEST_F() 135 MockRead(ASYNC, payload_read.data(), payload_read.size()) }; in TEST_F() 204 MockRead data_reads[] = { in TEST_F() 205 MockRead(SYNCHRONOUS, kSOCKS5GreetResponse, kSOCKS5GreetResponseLength), in TEST_F() 206 MockRead(SYNCHRONOUS, kSOCKS5OkResponse, kSOCKS5OkResponseLength) in TEST_F() 230 MockRead data_reads[] = {MockRead()}; in TEST_F() [all …]
|
D | socks_client_socket_unittest.cc | 33 MockRead reads[], size_t reads_count, 61 MockRead reads[], in BuildMockSocket() 144 MockRead data_reads[] = { in TEST_F() 145 MockRead(ASYNC, kSOCKSOkReply, arraysize(kSOCKSOkReply)), in TEST_F() 146 MockRead(ASYNC, payload_read.data(), payload_read.size()) }; in TEST_F() 220 MockRead data_reads[] = { in TEST_F() 221 MockRead(SYNCHRONOUS, tests[i].fail_reply, in TEST_F() 257 MockRead data_reads[] = { in TEST_F() 258 MockRead(ASYNC, kSOCKSPartialReply1, arraysize(kSOCKSPartialReply1)), in TEST_F() 259 MockRead(ASYNC, kSOCKSPartialReply2, arraysize(kSOCKSPartialReply2)) }; in TEST_F() [all …]
|
D | socket_test_util.h | 184 typedef MockReadWrite<MOCK_READ> MockRead; typedef 206 virtual MockRead GetNextRead() = 0; 233 virtual void OnReadComplete(const MockRead& data) = 0; 242 StaticSocketDataProvider(MockRead* reads, 249 const MockRead& PeekRead() const; 252 const MockRead& PeekRead(size_t index) const; 265 virtual MockRead GetNextRead() OVERRIDE; 270 MockRead* reads_; 295 virtual MockRead GetNextRead() OVERRIDE; 306 std::deque<MockRead> reads_; [all …]
|
D | socket_test_util.cc | 123 const char* stop = (r.sequence_number & MockRead::STOPLOOP) ? " (STOP)" : ""; in DumpMockReadWrite() 124 DVLOG(1) << "Stage: " << (r.sequence_number & ~MockRead::STOPLOOP) << stop in DumpMockReadWrite() 159 StaticSocketDataProvider::StaticSocketDataProvider(MockRead* reads, in StaticSocketDataProvider() 173 const MockRead& StaticSocketDataProvider::PeekRead() const { in PeekRead() 183 const MockRead& StaticSocketDataProvider::PeekRead(size_t index) const { in PeekRead() 193 MockRead StaticSocketDataProvider::GetNextRead() { in GetNextRead() 247 MockRead DynamicSocketDataProvider::GetNextRead() { in GetNextRead() 249 return MockRead(SYNCHRONOUS, ERR_UNEXPECTED); in GetNextRead() 250 MockRead result = reads_.front(); in GetNextRead() 270 reads_.push_back(MockRead(ASYNC, data, length)); in SimulateRead() [all …]
|
D | socks_client_socket_pool_unittest.cc | 74 reads_.reset(new MockRead[3]); in SOCKS5MockData() 75 reads_[0] = MockRead(mode, kSOCKS5GreetResponse, in SOCKS5MockData() 77 reads_[1] = MockRead(mode, kSOCKS5OkResponse, kSOCKS5OkResponseLength); in SOCKS5MockData() 78 reads_[2] = MockRead(mode, 0); in SOCKS5MockData() 89 scoped_ptr<MockRead[]> reads_; 233 MockRead failed_read[] = { in TEST_F() 234 MockRead(SYNCHRONOUS, 0), in TEST_F() 252 MockRead failed_read[] = { in TEST_F() 253 MockRead(ASYNC, 0), in TEST_F()
|
/external/chromium_org/net/http/ |
D | http_network_transaction_unittest.cc | 283 const MockRead* read_failure); 290 const MockRead* read_failure, 374 SimpleGetHelperResult SimpleGetHelper(MockRead data_reads[], in SimpleGetHelper() 381 int64 ReadsSize(MockRead data_reads[], size_t reads_count) { in ReadsSize() 388 void ConnectStatusHelperWithExpectedStatus(const MockRead& status, 391 void ConnectStatusHelper(const MockRead& status); 646 MockRead data_reads[] = { in TEST_P() 647 MockRead("HTTP/1.0 200 OK\r\n\r\n"), in TEST_P() 648 MockRead("hello world"), in TEST_P() 649 MockRead(SYNCHRONOUS, OK), in TEST_P() [all …]
|
D | http_network_layer_unittest.cc | 101 MockRead data_reads[] = { in TestProxyFallback() 102 MockRead("HTTP/1.1 200 OK\r\n" in TestProxyFallback() 104 MockRead("Bypass message"), in TestProxyFallback() 105 MockRead(SYNCHRONOUS, OK), in TestProxyFallback() 113 MockRead data_reads[], in TestProxyFallbackWithMockReads() 124 MockRead data_reads[], in TestProxyFallbackByMethodWithMockReads() 148 MockRead data_reads2[3]; in TestProxyFallbackByMethodWithMockReads() 150 data_reads2[data_reads2_index++] = MockRead("HTTP/1.0 200 OK\r\n" in TestProxyFallbackByMethodWithMockReads() 153 data_reads2[data_reads2_index++] = MockRead(content.c_str()); in TestProxyFallbackByMethodWithMockReads() 154 data_reads2[data_reads2_index++] = MockRead(SYNCHRONOUS, OK); in TestProxyFallbackByMethodWithMockReads() [all …]
|
D | http_proxy_client_socket_pool_unittest.cc | 255 void Initialize(MockRead* reads, size_t reads_count, in Initialize() 257 MockRead* spdy_reads, size_t spdy_reads_count, in Initialize() 371 MockRead reads[] = { in TEST_P() 373 MockRead(ASYNC, 1, "HTTP/1.1 407 Proxy Authentication Required\r\n"), in TEST_P() 374 MockRead(ASYNC, 2, "Proxy-Authenticate: Basic realm=\"MyRealm1\"\r\n"), in TEST_P() 375 MockRead(ASYNC, 3, "Content-Length: 10\r\n\r\n"), in TEST_P() 376 MockRead(ASYNC, 4, "0123456789"), in TEST_P() 392 MockRead spdy_reads[] = { in TEST_P() 394 MockRead(ASYNC, 0, 3) in TEST_P() 442 MockRead reads[] = { in TEST_P() [all …]
|
D | http_stream_parser_unittest.cc | 214 MockRead reads[] = { in TEST() 215 MockRead(ASYNC, 5, "HTTP/1.1 200 OK\r\n"), in TEST() 216 MockRead(ASYNC, 6, "Content-Length: 8\r\n\r\n"), in TEST() 217 MockRead(ASYNC, 7, "one.html"), in TEST() 218 MockRead(SYNCHRONOUS, 0, 8), // EOF in TEST() 326 MockRead truncated_status_reads[] = { in TEST() 327 MockRead(SYNCHRONOUS, 1, "HTTP/1.1 20"), in TEST() 328 MockRead(SYNCHRONOUS, 0, 2), // EOF in TEST() 331 MockRead truncated_after_status_reads[] = { in TEST() 332 MockRead(SYNCHRONOUS, 1, "HTTP/1.1 200 Ok\r\n"), in TEST() [all …]
|
/external/chromium_org/net/websockets/ |
D | websocket_basic_stream_test.cc | 85 StrictStaticSocketDataProvider(MockRead* reads, in StrictStaticSocketDataProvider() 119 scoped_ptr<ClientSocketHandle> MakeTransportSocket(MockRead reads[], in MakeTransportSocket() 146 void CreateStream(MockRead reads[], in CreateStream() 159 void CreateReadOnly(MockRead (&reads)[N]) { in CreateReadOnly() 183 void CreateRead(const MockRead& read) { in CreateRead() 188 MockRead reads_[1]; 216 reads_.reset(new MockRead[number_of_chunks]); in CreateChunkedRead() 225 reads_[i] = MockRead(mode, start, len); in CreateChunkedRead() 231 scoped_ptr<MockRead[]> reads_; 273 CreateRead(MockRead(SYNCHRONOUS, kSampleFrame, kSampleFrameSize)); in TEST_F() [all …]
|
/external/chromium_org/net/spdy/ |
D | spdy_proxy_client_socket_unittest.cc | 72 void Initialize(MockRead* reads, size_t reads_count, MockWrite* writes, 175 void SpdyProxyClientSocketTest::Initialize(MockRead* reads, in Initialize() 393 MockRead reads[] = { in TEST_P() 395 MockRead(ASYNC, 0, 2), // EOF in TEST_P() 414 MockRead reads[] = { in TEST_P() 416 MockRead(ASYNC, 0, 2), // EOF in TEST_P() 435 MockRead reads[] = { in TEST_P() 437 MockRead(ASYNC, 0, 2), // EOF in TEST_P() 457 MockRead reads[] = { in TEST_P() 458 CreateMockRead(*resp, 1, ASYNC), MockRead(ASYNC, 0, 3), // EOF in TEST_P() [all …]
|
D | spdy_network_transaction_unittest.cc | 420 void ConnectStatusHelperWithExpectedStatus(const MockRead& status, 423 void ConnectStatusHelper(const MockRead& status); 746 MockRead reads[] = { in TEST_P() 749 MockRead(ASYNC, 0, 0) // EOF in TEST_P() 818 MockRead reads[] = { in TEST_P() 821 MockRead(ASYNC, 0, 0) // EOF in TEST_P() 872 MockRead reads[] = { in TEST_P() 884 MockRead(ASYNC, 0, 0), // EOF in TEST_P() 961 MockRead reads[] = { in TEST_P() 968 MockRead(ASYNC, 0, 0), // EOF in TEST_P() [all …]
|
D | spdy_session_unittest.cc | 239 MockRead reads[] = {MockRead(ASYNC, 0, 0), }; in TEST_P() 293 MockRead reads[] = { in TEST_P() 323 MockRead reads[] = { in TEST_P() 350 MockRead reads[] = { in TEST_P() 352 MockRead(ASYNC, 0, 3) // EOF in TEST_P() 431 MockRead reads[] = { in TEST_P() 434 MockRead(ASYNC, 0, 4) // EOF in TEST_P() 510 MockRead reads[] = { in TEST_P() 512 MockRead(ASYNC, 0, 3) // EOF in TEST_P() 611 MockRead reads[] = { in TEST_P() [all …]
|
D | spdy_http_stream_unittest.cc | 90 void InitSessionDeterministic(MockRead* reads, size_t reads_count, in InitSessionDeterministic() 103 void InitSession(MockRead* reads, size_t reads_count, in InitSession() 139 MockRead reads[] = { in TEST_P() 140 MockRead(ASYNC, 0, 0) // EOF in TEST_P() 164 MockRead reads[] = { in TEST_P() 166 MockRead(SYNCHRONOUS, 0, 3) // EOF in TEST_P() 236 MockRead reads[] = { in TEST_P() 241 MockRead(ASYNC, 0, 6) // EOF in TEST_P() 328 std::vector<MockRead> reads; in TEST_P() 331 reads.push_back(MockRead(SYNCHRONOUS, 0, seq++)); // EOF in TEST_P() [all …]
|
D | spdy_websocket_stream_unittest.cc | 246 void InitSession(MockRead* reads, size_t reads_count, in InitSession() 317 MockRead reads[] = { in TEST_P() 322 MockRead(SYNCHRONOUS, 0, 8) // EOF cause OnCloseSpdyStream event. in TEST_P() 392 MockRead reads[] = { in TEST_P() 395 MockRead(SYNCHRONOUS, 0, 5) // EOF cause OnCloseSpdyStream event. in TEST_P() 447 MockRead reads[] = { in TEST_P() 450 MockRead(ASYNC, ERR_IO_PENDING, 5) in TEST_P() 509 MockRead reads[] = { in TEST_P() 512 MockRead(ASYNC, ERR_IO_PENDING, 6) in TEST_P() 573 MockRead reads[] = { in TEST_P() [all …]
|
D | spdy_session_pool_unittest.cc | 102 MockRead reads[] = { in TEST_P() 103 MockRead(SYNCHRONOUS, ERR_IO_PENDING) // Stall forever. in TEST_P() 141 MockRead reads[] = { in TEST_P() 142 MockRead(SYNCHRONOUS, ERR_IO_PENDING) // Stall forever. in TEST_P() 273 MockRead reads[] = { in TEST_P() 274 MockRead(SYNCHRONOUS, ERR_IO_PENDING) // Stall forever. in TEST_P() 363 MockRead reads[] = { in RunIPPoolingTest() 364 MockRead(SYNCHRONOUS, ERR_IO_PENDING) // Stall forever. in RunIPPoolingTest() 516 MockRead reads[] = { in TEST_P() 517 MockRead(SYNCHRONOUS, ERR_IO_PENDING) // Stall forever. in TEST_P()
|
/external/chromium_org/google_apis/gcm/engine/ |
D | connection_handler_impl_unittest.cc | 25 typedef std::vector<net::MockRead> ReadList; 239 ReadList read_list(1, net::MockRead(net::ASYNC, in TEST_F() 264 ReadList read_list(1, net::MockRead(net::ASYNC, in TEST_F() 285 ReadList read_list(1, net::MockRead(net::SYNCHRONOUS, in TEST_F() 307 read_list.push_back(net::MockRead(net::ASYNC, in TEST_F() 310 read_list.push_back(net::MockRead(net::SYNCHRONOUS, in TEST_F() 329 ReadList read_list(1, net::MockRead(net::SYNCHRONOUS, in TEST_F() 343 read_list[0] = net::MockRead(net::ASYNC, in TEST_F() 369 read_list.push_back(net::MockRead(net::ASYNC, in TEST_F() 372 read_list.push_back(net::MockRead(net::ASYNC, in TEST_F() [all …]
|
/external/chromium_org/net/socket_stream/ |
D | socket_stream_unittest.cc | 411 MockRead data_reads[] = { in TEST_F() 412 MockRead(SocketStreamTest::kWebSocketHandshakeResponse), in TEST_F() 414 MockRead(ASYNC, ERR_IO_PENDING) in TEST_F() 527 MockRead data_reads1[] = { in TEST_F() 528 MockRead("HTTP/1.1 407 Proxy Authentication Required\r\n"), in TEST_F() 529 MockRead("Proxy-Authenticate: Basic realm=\"MyRealm1\"\r\n"), in TEST_F() 530 MockRead("\r\n"), in TEST_F() 542 MockRead data_reads2[] = { in TEST_F() 543 MockRead("HTTP/1.1 200 Connection Established\r\n"), in TEST_F() 544 MockRead("Proxy-agent: Apache/2.2.8\r\n"), in TEST_F() [all …]
|
/external/chromium_org/google_apis/gcm/base/ |
D | socket_stream_unittest.cc | 19 typedef std::vector<net::MockRead> ReadList; 198 BuildSocket(ReadList(1, net::MockRead(net::SYNCHRONOUS, in TEST_F() 214 net::MockRead(net::SYNCHRONOUS, in TEST_F() 218 net::MockRead(net::SYNCHRONOUS, in TEST_F() 234 net::MockRead(net::SYNCHRONOUS, net::ERR_IO_PENDING)); in TEST_F() 236 net::MockRead(net::ASYNC, kReadData, first_read_len)); in TEST_F() 238 net::MockRead(net::ASYNC, &kReadData[first_read_len], second_read_len)); in TEST_F() 254 BuildSocket(ReadList(1, net::MockRead(net::SYNCHRONOUS, in TEST_F() 273 BuildSocket(ReadList(1, net::MockRead(net::SYNCHRONOUS, in TEST_F() 291 BuildSocket(ReadList(1, net::MockRead(net::SYNCHRONOUS, result)), in TEST_F() [all …]
|
/external/chromium_org/jingle/glue/ |
D | chrome_async_socket_unittest.cc | 46 virtual net::MockRead GetNextRead() OVERRIDE { in GetNextRead() 50 const net::MockRead pending_read(net::SYNCHRONOUS, net::ERR_IO_PENDING); in GetNextRead() 53 net::MockRead mock_read = reads_.front(); in GetNextRead() 81 void AddRead(const net::MockRead& mock_read) { in AddRead() 97 std::deque<net::MockRead> reads_; 378 async_socket_data_provider_.AddRead(net::MockRead(kDummyData)); in DoSSLOpenClosed() 633 async_socket_data_provider_.AddRead(net::MockRead(kReadData)); in TEST_F() 647 async_socket_data_provider_.AddRead(net::MockRead(kReadData)); in TEST_F() 658 async_socket_data_provider_.AddRead(net::MockRead(kReadData2)); in TEST_F() 669 async_socket_data_provider_.AddRead(net::MockRead(kReadData)); in TEST_F() [all …]
|
/external/chromium_org/components/data_reduction_proxy/browser/ |
D | data_reduction_proxy_protocol_unittest.cc | 33 using net::MockRead; 124 MockRead data_reads[] = { in TestProxyFallback() 125 MockRead(first_response), in TestProxyFallback() 126 MockRead(payload1.c_str()), in TestProxyFallback() 127 MockRead(net::SYNCHRONOUS, net::OK), in TestProxyFallback() 148 MockRead data_reads2[] = { in TestProxyFallback() 149 MockRead("HTTP/1.0 200 OK\r\n" in TestProxyFallback() 151 MockRead("content"), in TestProxyFallback() 152 MockRead(net::SYNCHRONOUS, net::OK), in TestProxyFallback() 773 MockRead data_reads[] = { in TEST_F() [all …]
|