| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 <cstddef> | 5 #include <cstddef> |
| 6 #include <string> | 6 #include <string> |
| 7 #include <vector> | 7 #include <vector> |
| 8 | 8 |
| 9 #include "base/memory/ref_counted.h" | 9 #include "base/memory/ref_counted.h" |
| 10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
| (...skipping 276 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 287 | 287 |
| 288 const SpdyStreamId stream_id = delegate.stream_id(); | 288 const SpdyStreamId stream_id = delegate.stream_id(); |
| 289 | 289 |
| 290 EXPECT_TRUE(delegate.send_headers_completed()); | 290 EXPECT_TRUE(delegate.send_headers_completed()); |
| 291 EXPECT_EQ("200", delegate.GetResponseHeaderValue(spdy_util_.GetStatusKey())); | 291 EXPECT_EQ("200", delegate.GetResponseHeaderValue(spdy_util_.GetStatusKey())); |
| 292 EXPECT_EQ(std::string(kPostBody, kPostBodyLength), | 292 EXPECT_EQ(std::string(kPostBody, kPostBodyLength), |
| 293 delegate.TakeReceivedData()); | 293 delegate.TakeReceivedData()); |
| 294 EXPECT_TRUE(data.at_write_eof()); | 294 EXPECT_TRUE(data.at_write_eof()); |
| 295 | 295 |
| 296 // Check that the NetLog was filled reasonably. | 296 // Check that the NetLog was filled reasonably. |
| 297 net::CapturingNetLog::CapturedEntryList entries; | 297 net::TestNetLog::CapturedEntryList entries; |
| 298 log.GetEntries(&entries); | 298 log.GetEntries(&entries); |
| 299 EXPECT_LT(0u, entries.size()); | 299 EXPECT_LT(0u, entries.size()); |
| 300 | 300 |
| 301 // Check that we logged SPDY_STREAM_ERROR correctly. | 301 // Check that we logged SPDY_STREAM_ERROR correctly. |
| 302 int pos = net::ExpectLogContainsSomewhere( | 302 int pos = net::ExpectLogContainsSomewhere( |
| 303 entries, 0, net::NetLog::TYPE_HTTP2_STREAM_ERROR, | 303 entries, 0, net::NetLog::TYPE_HTTP2_STREAM_ERROR, |
| 304 net::NetLog::PHASE_NONE); | 304 net::NetLog::PHASE_NONE); |
| 305 | 305 |
| 306 int stream_id2; | 306 int stream_id2; |
| 307 ASSERT_TRUE(entries[pos].GetIntegerValue("stream_id", &stream_id2)); | 307 ASSERT_TRUE(entries[pos].GetIntegerValue("stream_id", &stream_id2)); |
| (...skipping 732 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1040 data.RunFor(1); // FIN | 1040 data.RunFor(1); // FIN |
| 1041 | 1041 |
| 1042 EXPECT_EQ(ERR_CONNECTION_CLOSED, delegate.WaitForClose()); | 1042 EXPECT_EQ(ERR_CONNECTION_CLOSED, delegate.WaitForClose()); |
| 1043 } | 1043 } |
| 1044 | 1044 |
| 1045 } // namespace | 1045 } // namespace |
| 1046 | 1046 |
| 1047 } // namespace test | 1047 } // namespace test |
| 1048 | 1048 |
| 1049 } // namespace net | 1049 } // namespace net |
| OLD | NEW |