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

Side by Side Diff: net/spdy/spdy_http_stream_spdy3_unittest.cc

Issue 14189003: [SPDY] Incorporate latest framing changes from HTTP2 into SPDY 4 as SPDY 4a2. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase Created 7 years, 7 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
OLDNEW
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/spdy/spdy_http_stream.h" 5 #include "net/spdy/spdy_http_stream.h"
6 6
7 #include <vector> 7 #include <vector>
8 8
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "base/stl_util.h" 10 #include "base/stl_util.h"
(...skipping 376 matching lines...) Expand 10 before | Expand all | Expand 10 after
387 EXPECT_FALSE(http_session_->spdy_session_pool()->HasSession(pair)); 387 EXPECT_FALSE(http_session_->spdy_session_pool()->HasSession(pair));
388 EXPECT_TRUE(data()->at_read_eof()); 388 EXPECT_TRUE(data()->at_read_eof());
389 EXPECT_TRUE(data()->at_write_eof()); 389 EXPECT_TRUE(data()->at_write_eof());
390 } 390 }
391 391
392 TEST_F(SpdyHttpStreamSpdy3Test, SendChunkedPost) { 392 TEST_F(SpdyHttpStreamSpdy3Test, SendChunkedPost) {
393 RunSendChunkedPostTest(kSpdyVersion3); 393 RunSendChunkedPostTest(kSpdyVersion3);
394 } 394 }
395 395
396 TEST_F(SpdyHttpStreamSpdy3Test, SendChunkedPost4) { 396 TEST_F(SpdyHttpStreamSpdy3Test, SendChunkedPost4) {
397 session_deps_.protocol = kProtoSPDY4a1; 397 session_deps_.protocol = kProtoSPDY4a2;
398 RunSendChunkedPostTest(kSpdyVersion4); 398 RunSendChunkedPostTest(kSpdyVersion4);
399 } 399 }
400 400
401 // Test to ensure the SpdyStream state machine does not get confused when a 401 // Test to ensure the SpdyStream state machine does not get confused when a
402 // chunk becomes available while a write is pending. 402 // chunk becomes available while a write is pending.
403 TEST_F(SpdyHttpStreamSpdy3Test, DelayedSendChunkedPost) { 403 TEST_F(SpdyHttpStreamSpdy3Test, DelayedSendChunkedPost) {
404 const char kUploadData1[] = "12345678"; 404 const char kUploadData1[] = "12345678";
405 const int kUploadData1Size = arraysize(kUploadData1)-1; 405 const int kUploadData1Size = arraysize(kUploadData1)-1;
406 scoped_ptr<SpdyFrame> req(ConstructChunkedSpdyPost(NULL, 0)); 406 scoped_ptr<SpdyFrame> req(ConstructChunkedSpdyPost(NULL, 0));
407 scoped_ptr<SpdyFrame> chunk1(ConstructSpdyBodyFrame(1, false)); 407 scoped_ptr<SpdyFrame> chunk1(ConstructSpdyBodyFrame(1, false));
(...skipping 622 matching lines...) Expand 10 before | Expand all | Expand 10 after
1030 data.RunFor(1); 1030 data.RunFor(1);
1031 sequenced_worker_pool->Shutdown(); 1031 sequenced_worker_pool->Shutdown();
1032 } 1032 }
1033 1033
1034 #endif // !defined(USE_OPENSSL) 1034 #endif // !defined(USE_OPENSSL)
1035 1035
1036 // TODO(willchan): Write a longer test for SpdyStream that exercises all 1036 // TODO(willchan): Write a longer test for SpdyStream that exercises all
1037 // methods. 1037 // methods.
1038 1038
1039 } // namespace net 1039 } // namespace net
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698