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

Side by Side Diff: net/http/http_transaction_unittest.h

Issue 201065: Http cache: Convert data writes from sysnchronous to asynchronous.... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 3 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 | Annotate | Revision Log
« no previous file with comments | « net/http/http_cache_unittest.cc ('k') | no next file » | 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) 2006-2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2009 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_HTTP_HTTP_TRANSACTION_UNITTEST_H_ 5 #ifndef NET_HTTP_HTTP_TRANSACTION_UNITTEST_H_
6 #define NET_HTTP_HTTP_TRANSACTION_UNITTEST_H_ 6 #define NET_HTTP_HTTP_TRANSACTION_UNITTEST_H_
7 7
8 #include "net/http/http_transaction.h" 8 #include "net/http/http_transaction.h"
9 9
10 #include <algorithm> 10 #include <algorithm>
(...skipping 15 matching lines...) Expand all
26 //----------------------------------------------------------------------------- 26 //-----------------------------------------------------------------------------
27 // mock transaction data 27 // mock transaction data
28 28
29 // these flags may be combined to form the test_mode field 29 // these flags may be combined to form the test_mode field
30 enum { 30 enum {
31 TEST_MODE_NORMAL = 0, 31 TEST_MODE_NORMAL = 0,
32 TEST_MODE_SYNC_NET_START = 1 << 0, 32 TEST_MODE_SYNC_NET_START = 1 << 0,
33 TEST_MODE_SYNC_NET_READ = 1 << 1, 33 TEST_MODE_SYNC_NET_READ = 1 << 1,
34 TEST_MODE_SYNC_CACHE_START = 1 << 2, 34 TEST_MODE_SYNC_CACHE_START = 1 << 2,
35 TEST_MODE_SYNC_CACHE_READ = 1 << 3, 35 TEST_MODE_SYNC_CACHE_READ = 1 << 3,
36 TEST_MODE_SYNC_CACHE_WRITE = 1 << 4,
36 }; 37 };
37 38
38 typedef void (*MockTransactionHandler)(const net::HttpRequestInfo* request, 39 typedef void (*MockTransactionHandler)(const net::HttpRequestInfo* request,
39 std::string* response_status, 40 std::string* response_status,
40 std::string* response_headers, 41 std::string* response_headers,
41 std::string* response_data); 42 std::string* response_data);
42 43
43 struct MockTransaction { 44 struct MockTransaction {
44 const char* url; 45 const char* url;
45 const char* method; 46 const char* method;
(...skipping 282 matching lines...) Expand 10 before | Expand all | Expand 10 after
328 }; 329 };
329 330
330 331
331 //----------------------------------------------------------------------------- 332 //-----------------------------------------------------------------------------
332 // helpers 333 // helpers
333 334
334 // read the transaction completely 335 // read the transaction completely
335 int ReadTransaction(net::HttpTransaction* trans, std::string* result); 336 int ReadTransaction(net::HttpTransaction* trans, std::string* result);
336 337
337 #endif // NET_HTTP_HTTP_TRANSACTION_UNITTEST_H_ 338 #endif // NET_HTTP_HTTP_TRANSACTION_UNITTEST_H_
OLDNEW
« no previous file with comments | « net/http/http_cache_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698