| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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/cert/caching_cert_verifier.h" | 5 #include "net/cert/caching_cert_verifier.h" |
| 6 | 6 |
| 7 #include <memory> | 7 #include <memory> |
| 8 | 8 |
| 9 #include "base/files/file_path.h" | 9 #include "base/files/file_path.h" |
| 10 #include "base/memory/ptr_util.h" | 10 #include "base/memory/ptr_util.h" |
| 11 #include "base/memory/ref_counted.h" | 11 #include "base/memory/ref_counted.h" |
| 12 #include "net/base/net_errors.h" | 12 #include "net/base/net_errors.h" |
| 13 #include "net/base/test_completion_callback.h" | 13 #include "net/base/test_completion_callback.h" |
| 14 #include "net/cert/cert_verifier.h" | 14 #include "net/cert/cert_verifier.h" |
| 15 #include "net/cert/cert_verify_result.h" | 15 #include "net/cert/cert_verify_result.h" |
| 16 #include "net/cert/mock_cert_verifier.h" | 16 #include "net/cert/mock_cert_verifier.h" |
| 17 #include "net/cert/x509_certificate.h" | 17 #include "net/cert/x509_certificate.h" |
| 18 #include "net/log/net_log.h" | 18 #include "net/log/net_log_with_source.h" |
| 19 #include "net/test/cert_test_util.h" | 19 #include "net/test/cert_test_util.h" |
| 20 #include "net/test/gtest_util.h" | 20 #include "net/test/gtest_util.h" |
| 21 #include "net/test/test_data_directory.h" | 21 #include "net/test/test_data_directory.h" |
| 22 #include "testing/gmock/include/gmock/gmock.h" | 22 #include "testing/gmock/include/gmock/gmock.h" |
| 23 #include "testing/gtest/include/gtest/gtest.h" | 23 #include "testing/gtest/include/gtest/gtest.h" |
| 24 | 24 |
| 25 using net::test::IsError; | 25 using net::test::IsError; |
| 26 using net::test::IsOk; | 26 using net::test::IsOk; |
| 27 | 27 |
| 28 using testing::_; | 28 using testing::_; |
| (...skipping 242 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 271 std::string(), CertificateList()), | 271 std::string(), CertificateList()), |
| 272 nullptr, &verify_result, callback.callback(), &request, | 272 nullptr, &verify_result, callback.callback(), &request, |
| 273 NetLogWithSource())); | 273 NetLogWithSource())); |
| 274 ASSERT_TRUE(IsCertificateError(error)); | 274 ASSERT_TRUE(IsCertificateError(error)); |
| 275 ASSERT_EQ(2u, verifier_.requests()); | 275 ASSERT_EQ(2u, verifier_.requests()); |
| 276 ASSERT_EQ(0u, verifier_.cache_hits()); | 276 ASSERT_EQ(0u, verifier_.cache_hits()); |
| 277 ASSERT_EQ(2u, verifier_.GetCacheSize()); | 277 ASSERT_EQ(2u, verifier_.GetCacheSize()); |
| 278 } | 278 } |
| 279 | 279 |
| 280 } // namespace net | 280 } // namespace net |
| OLD | NEW |