| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 #include "net/quic/quic_session.h" | 5 #include "net/quic/quic_session.h" |
| 6 | 6 |
| 7 #include <set> | 7 #include <set> |
| 8 | 8 |
| 9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
| 10 #include "base/containers/hash_tables.h" | 10 #include "base/containers/hash_tables.h" |
| (...skipping 371 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 382 EXPECT_DEBUG_DFATAL(session_.MarkConnectionLevelWriteBlocked( | 382 EXPECT_DEBUG_DFATAL(session_.MarkConnectionLevelWriteBlocked( |
| 383 closed_stream_id, kSomeMiddlePriority), | 383 closed_stream_id, kSomeMiddlePriority), |
| 384 "Marking unknown stream 2 blocked."); | 384 "Marking unknown stream 2 blocked."); |
| 385 } | 385 } |
| 386 | 386 |
| 387 TEST_P(QuicSessionTestServer, | 387 TEST_P(QuicSessionTestServer, |
| 388 DebugDFatalIfMarkWriteBlockedCalledWithWrongPriority) { | 388 DebugDFatalIfMarkWriteBlockedCalledWithWrongPriority) { |
| 389 const QuicPriority kDifferentPriority = 0; | 389 const QuicPriority kDifferentPriority = 0; |
| 390 | 390 |
| 391 TestStream* stream2 = session_.CreateOutgoingDynamicStream(); | 391 TestStream* stream2 = session_.CreateOutgoingDynamicStream(); |
| 392 EXPECT_NE(kDifferentPriority, stream2->EffectivePriority()); | 392 EXPECT_NE(kDifferentPriority, stream2->Priority()); |
| 393 EXPECT_DEBUG_DFATAL(session_.MarkConnectionLevelWriteBlocked( | 393 EXPECT_DEBUG_DFATAL(session_.MarkConnectionLevelWriteBlocked( |
| 394 stream2->id(), kDifferentPriority), | 394 stream2->id(), kDifferentPriority), |
| 395 "Priorities do not match. Got: 0 Expected: 3"); | 395 "Priorities do not match. Got: 0 Expected: 3"); |
| 396 } | 396 } |
| 397 | 397 |
| 398 TEST_P(QuicSessionTestServer, OnCanWrite) { | 398 TEST_P(QuicSessionTestServer, OnCanWrite) { |
| 399 TestStream* stream2 = session_.CreateOutgoingDynamicStream(); | 399 TestStream* stream2 = session_.CreateOutgoingDynamicStream(); |
| 400 TestStream* stream4 = session_.CreateOutgoingDynamicStream(); | 400 TestStream* stream4 = session_.CreateOutgoingDynamicStream(); |
| 401 TestStream* stream6 = session_.CreateOutgoingDynamicStream(); | 401 TestStream* stream6 = session_.CreateOutgoingDynamicStream(); |
| 402 | 402 |
| (...skipping 782 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1185 // Verify that there is no entry for the stream in | 1185 // Verify that there is no entry for the stream in |
| 1186 // locally_closed_streams_highest_offset_. | 1186 // locally_closed_streams_highest_offset_. |
| 1187 EXPECT_EQ( | 1187 EXPECT_EQ( |
| 1188 FLAGS_quic_fix_fin_accounting ? 0u : 1u, | 1188 FLAGS_quic_fix_fin_accounting ? 0u : 1u, |
| 1189 QuicSessionPeer::GetLocallyClosedStreamsHighestOffset(&session_).size()); | 1189 QuicSessionPeer::GetLocallyClosedStreamsHighestOffset(&session_).size()); |
| 1190 } | 1190 } |
| 1191 | 1191 |
| 1192 } // namespace | 1192 } // namespace |
| 1193 } // namespace test | 1193 } // namespace test |
| 1194 } // namespace net | 1194 } // namespace net |
| OLD | NEW |