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

Side by Side Diff: net/url_request/url_request_unittest.cc

Issue 275953002: Remove HTTP pipelining support. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix line endings Created 6 years, 6 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
« no previous file with comments | « net/url_request/url_request_context_builder.cc ('k') | tools/metrics/histograms/histograms.xml » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 "build/build_config.h" 5 #include "build/build_config.h"
6 6
7 #if defined(OS_WIN) 7 #if defined(OS_WIN)
8 #include <windows.h> 8 #include <windows.h>
9 #include <shlobj.h> 9 #include <shlobj.h>
10 #endif 10 #endif
(...skipping 1693 matching lines...) Expand 10 before | Expand all | Expand 10 after
1704 EXPECT_EQ(job_load_timing.connect_timing.ssl_end, 1704 EXPECT_EQ(job_load_timing.connect_timing.ssl_end,
1705 load_timing_result.connect_timing.ssl_end); 1705 load_timing_result.connect_timing.ssl_end);
1706 1706
1707 // Redundant sanity check. 1707 // Redundant sanity check.
1708 TestLoadTimingNotReusedWithProxy(load_timing_result, 1708 TestLoadTimingNotReusedWithProxy(load_timing_result,
1709 CONNECT_TIMING_HAS_SSL_TIMES); 1709 CONNECT_TIMING_HAS_SSL_TIMES);
1710 } 1710 }
1711 1711
1712 // Make sure that URLRequest correctly adjusts proxy times when they're before 1712 // Make sure that URLRequest correctly adjusts proxy times when they're before
1713 // |request_start|, due to already having a connected socket. This happens in 1713 // |request_start|, due to already having a connected socket. This happens in
1714 // the case of reusing a SPDY session or HTTP pipeline. The connected socket is 1714 // the case of reusing a SPDY session. The connected socket is not considered
1715 // not considered reused in this test (May be a preconnect). 1715 // reused in this test (May be a preconnect).
1716 // 1716 //
1717 // To mix things up from the test above, assumes DNS times but no SSL times. 1717 // To mix things up from the test above, assumes DNS times but no SSL times.
1718 TEST_F(URLRequestTest, InterceptLoadTimingEarlyProxyResolution) { 1718 TEST_F(URLRequestTest, InterceptLoadTimingEarlyProxyResolution) {
1719 base::TimeTicks now = base::TimeTicks::Now(); 1719 base::TimeTicks now = base::TimeTicks::Now();
1720 LoadTimingInfo job_load_timing = 1720 LoadTimingInfo job_load_timing =
1721 NormalLoadTimingInfo(now, CONNECT_TIMING_HAS_DNS_TIMES, true); 1721 NormalLoadTimingInfo(now, CONNECT_TIMING_HAS_DNS_TIMES, true);
1722 job_load_timing.proxy_resolve_start = now - base::TimeDelta::FromDays(6); 1722 job_load_timing.proxy_resolve_start = now - base::TimeDelta::FromDays(6);
1723 job_load_timing.proxy_resolve_end = now - base::TimeDelta::FromDays(5); 1723 job_load_timing.proxy_resolve_end = now - base::TimeDelta::FromDays(5);
1724 job_load_timing.connect_timing.dns_start = now - base::TimeDelta::FromDays(4); 1724 job_load_timing.connect_timing.dns_start = now - base::TimeDelta::FromDays(4);
1725 job_load_timing.connect_timing.dns_end = now - base::TimeDelta::FromDays(3); 1725 job_load_timing.connect_timing.dns_end = now - base::TimeDelta::FromDays(3);
(...skipping 6287 matching lines...) Expand 10 before | Expand all | Expand 10 after
8013 8013
8014 EXPECT_FALSE(r.is_pending()); 8014 EXPECT_FALSE(r.is_pending());
8015 EXPECT_EQ(1, d->response_started_count()); 8015 EXPECT_EQ(1, d->response_started_count());
8016 EXPECT_FALSE(d->received_data_before_response()); 8016 EXPECT_FALSE(d->received_data_before_response());
8017 EXPECT_EQ(d->bytes_received(), static_cast<int>(file_size)); 8017 EXPECT_EQ(d->bytes_received(), static_cast<int>(file_size));
8018 } 8018 }
8019 } 8019 }
8020 #endif // !defined(DISABLE_FTP_SUPPORT) 8020 #endif // !defined(DISABLE_FTP_SUPPORT)
8021 8021
8022 } // namespace net 8022 } // namespace net
OLDNEW
« no previous file with comments | « net/url_request/url_request_context_builder.cc ('k') | tools/metrics/histograms/histograms.xml » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698