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

Unified Diff: net/quic/test_tools/quic_spdy_session_peer.h

Issue 2854833005: QUIC - stream id refactor for tests. (Closed)
Patch Set: rebase Created 3 years, 8 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
Index: net/quic/test_tools/quic_spdy_session_peer.h
diff --git a/net/quic/test_tools/quic_spdy_session_peer.h b/net/quic/test_tools/quic_spdy_session_peer.h
index e48bcef3f3ee15262f32946329a7881d961d904d..feb09920034baa8c63637aa1ce00fbae98d0e3b6 100644
--- a/net/quic/test_tools/quic_spdy_session_peer.h
+++ b/net/quic/test_tools/quic_spdy_session_peer.h
@@ -41,6 +41,18 @@ class QuicSpdySessionPeer {
bool fin,
SpdyPriority priority,
QuicReferenceCountedPointer<QuicAckListenerInterface> ack_listener);
+ // Helper functions for stream ids, to allow test logic to abstract
+ // over the HTTP stream numbering scheme (i.e. whether one or
+ // two QUIC streams are used per HTTP transaction).
+ static QuicStreamId NextStreamId(const QuicSpdySession& session);
+ // n should start at 0.
+ static QuicStreamId GetNthClientInitiatedStreamId(
+ const QuicSpdySession& session,
+ int n);
+ // n should start at 0.
+ static QuicStreamId GetNthServerInitiatedStreamId(
+ const QuicSpdySession& session,
+ int n);
private:
DISALLOW_COPY_AND_ASSIGN(QuicSpdySessionPeer);

Powered by Google App Engine
This is Rietveld 408576698