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 "net/http/http_network_transaction.h" | 5 #include "net/http/http_network_transaction.h" |
6 | 6 |
7 #include <math.h> // ceil | 7 #include <math.h> // ceil |
8 #include <stdarg.h> | 8 #include <stdarg.h> |
9 #include <string> | 9 #include <string> |
10 #include <vector> | 10 #include <vector> |
(...skipping 541 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
552 cert_verifier, | 552 cert_verifier, |
553 NULL, | 553 NULL, |
554 NULL, | 554 NULL, |
555 NULL, | 555 NULL, |
556 std::string(), | 556 std::string(), |
557 NULL, | 557 NULL, |
558 NULL, | 558 NULL, |
559 NULL, | 559 NULL, |
560 NULL, | 560 NULL, |
561 NULL, | 561 NULL, |
562 NULL) {} | 562 false, |
| 563 NULL) { |
| 564 } |
563 | 565 |
564 //----------------------------------------------------------------------------- | 566 //----------------------------------------------------------------------------- |
565 | 567 |
566 // Helper functions for validating that AuthChallengeInfo's are correctly | 568 // Helper functions for validating that AuthChallengeInfo's are correctly |
567 // configured for common cases. | 569 // configured for common cases. |
568 bool CheckBasicServerAuth(const AuthChallengeInfo* auth_challenge) { | 570 bool CheckBasicServerAuth(const AuthChallengeInfo* auth_challenge) { |
569 if (!auth_challenge) | 571 if (!auth_challenge) |
570 return false; | 572 return false; |
571 EXPECT_FALSE(auth_challenge->is_proxy); | 573 EXPECT_FALSE(auth_challenge->is_proxy); |
572 EXPECT_EQ("www.google.com:80", auth_challenge->challenger.ToString()); | 574 EXPECT_EQ("www.google.com:80", auth_challenge->challenger.ToString()); |
(...skipping 12525 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
13098 EXPECT_EQ(ERR_IO_PENDING, rv); | 13100 EXPECT_EQ(ERR_IO_PENDING, rv); |
13099 | 13101 |
13100 rv = callback.WaitForResult(); | 13102 rv = callback.WaitForResult(); |
13101 EXPECT_EQ(ERR_CONNECTION_RESET, rv); | 13103 EXPECT_EQ(ERR_CONNECTION_RESET, rv); |
13102 | 13104 |
13103 const HttpResponseInfo* response = trans->GetResponseInfo(); | 13105 const HttpResponseInfo* response = trans->GetResponseInfo(); |
13104 EXPECT_TRUE(response == NULL); | 13106 EXPECT_TRUE(response == NULL); |
13105 } | 13107 } |
13106 | 13108 |
13107 } // namespace net | 13109 } // namespace net |
OLD | NEW |