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

Unified Diff: net/tools/quic/test_tools/push_promise_delegate.cc

Issue 2458793002: Server push cancellation: add PushPromiseHelper which reflects information on the push promise. (Closed)
Patch Set: sync and fix tests Created 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « net/tools/quic/test_tools/push_promise_delegate.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/tools/quic/test_tools/push_promise_delegate.cc
diff --git a/net/tools/quic/test_tools/push_promise_delegate.cc b/net/tools/quic/test_tools/push_promise_delegate.cc
new file mode 100644
index 0000000000000000000000000000000000000000..a9ba80eab72a2286780b165257f01bf58a7b56ff
--- /dev/null
+++ b/net/tools/quic/test_tools/push_promise_delegate.cc
@@ -0,0 +1,25 @@
+// Copyright 2016 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "net/tools/quic/test_tools/push_promise_delegate.h"
+
+namespace net {
+namespace test {
+PushPromiseDelegate::PushPromiseDelegate(bool match)
+ : match_(match), rendezvous_fired_(false), rendezvous_stream_(nullptr) {}
+
+bool PushPromiseDelegate::CheckVary(const SpdyHeaderBlock& client_request,
+ const SpdyHeaderBlock& promise_request,
+ const SpdyHeaderBlock& promise_response) {
+ DVLOG(1) << "match " << match_;
+ return match_;
+}
+
+void PushPromiseDelegate::OnRendezvousResult(QuicSpdyStream* stream) {
+ rendezvous_fired_ = true;
+ rendezvous_stream_ = stream;
+}
+
+} // namespace test
+} // namespace net
« no previous file with comments | « net/tools/quic/test_tools/push_promise_delegate.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698