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 "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 8000 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
8011 | 8011 |
8012 base::RunLoop().Run(); | 8012 base::RunLoop().Run(); |
8013 | 8013 |
8014 EXPECT_EQ(1, d.on_certificate_requested_count()); | 8014 EXPECT_EQ(1, d.on_certificate_requested_count()); |
8015 EXPECT_FALSE(d.received_data_before_response()); | 8015 EXPECT_FALSE(d.received_data_before_response()); |
8016 EXPECT_EQ(0, d.bytes_received()); | 8016 EXPECT_EQ(0, d.bytes_received()); |
8017 | 8017 |
8018 // Send no certificate. | 8018 // Send no certificate. |
8019 // TODO(davidben): Get temporary client cert import (with keys) working on | 8019 // TODO(davidben): Get temporary client cert import (with keys) working on |
8020 // all platforms so we can test sending a cert as well. | 8020 // all platforms so we can test sending a cert as well. |
8021 r->ContinueWithCertificate(NULL); | 8021 r->ContinueWithCertificate(nullptr, nullptr); |
8022 | 8022 |
8023 base::RunLoop().Run(); | 8023 base::RunLoop().Run(); |
8024 | 8024 |
8025 EXPECT_EQ(1, d.response_started_count()); | 8025 EXPECT_EQ(1, d.response_started_count()); |
8026 EXPECT_FALSE(d.received_data_before_response()); | 8026 EXPECT_FALSE(d.received_data_before_response()); |
8027 EXPECT_NE(0, d.bytes_received()); | 8027 EXPECT_NE(0, d.bytes_received()); |
8028 } | 8028 } |
8029 } | 8029 } |
8030 | 8030 |
8031 TEST_F(HTTPSRequestTest, ResumeTest) { | 8031 TEST_F(HTTPSRequestTest, ResumeTest) { |
(...skipping 1480 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
9512 | 9512 |
9513 req->Start(); | 9513 req->Start(); |
9514 req->Cancel(); | 9514 req->Cancel(); |
9515 job->DetachRequest(); | 9515 job->DetachRequest(); |
9516 base::RunLoop().RunUntilIdle(); | 9516 base::RunLoop().RunUntilIdle(); |
9517 EXPECT_EQ(URLRequestStatus::CANCELED, req->status().status()); | 9517 EXPECT_EQ(URLRequestStatus::CANCELED, req->status().status()); |
9518 EXPECT_EQ(0, d.received_redirect_count()); | 9518 EXPECT_EQ(0, d.received_redirect_count()); |
9519 } | 9519 } |
9520 | 9520 |
9521 } // namespace net | 9521 } // namespace net |
OLD | NEW |