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

Unified Diff: net/http/http_transaction_test_util.h

Issue 2519473002: Fixes the cache lock issue. (Closed)
Patch Set: Feedback addressed Created 3 years, 10 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « net/http/http_transaction.h ('k') | net/http/http_transaction_test_util.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/http/http_transaction_test_util.h
diff --git a/net/http/http_transaction_test_util.h b/net/http/http_transaction_test_util.h
index e936ac9de01d745783c1f2981d98f55df3a60664..afdb4e5701e8f725ac9f0675a2d367403a579315 100644
--- a/net/http/http_transaction_test_util.h
+++ b/net/http/http_transaction_test_util.h
@@ -9,11 +9,14 @@
#include <stdint.h>
+#include <memory>
#include <string>
+#include <vector>
#include "base/callback.h"
#include "base/compiler_specific.h"
#include "base/memory/weak_ptr.h"
+#include "base/run_loop.h"
#include "base/strings/string16.h"
#include "net/base/io_buffer.h"
#include "net/base/load_flags.h"
@@ -201,6 +204,7 @@ class MockNetworkTransaction
int Read(IOBuffer* buf,
int buf_len,
const CompletionCallback& callback) override;
+
void PopulateNetErrorDetails(NetErrorDetails* details) const override;
void StopCaching() override;
@@ -281,7 +285,6 @@ class MockNetworkTransaction
bool done_reading_called_;
base::WeakPtrFactory<MockNetworkTransaction> weak_factory_;
-
};
class MockNetworkLayer : public HttpTransactionFactory,
@@ -347,6 +350,15 @@ class MockNetworkLayer : public HttpTransactionFactory,
base::WeakPtr<MockNetworkTransaction> last_transaction_;
};
+struct Context {
+ Context();
+ ~Context();
+
+ int result;
+ TestCompletionCallback callback;
+ std::unique_ptr<HttpTransaction> trans;
+};
+
//-----------------------------------------------------------------------------
// helpers
« no previous file with comments | « net/http/http_transaction.h ('k') | net/http/http_transaction_test_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698