| 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 "net/base/cert_test_util.h" | 5 #include "net/test/cert_test_util.h" |
| 6 | 6 |
| 7 #include "base/file_util.h" | 7 #include "base/file_util.h" |
| 8 #include "base/files/file_path.h" | 8 #include "base/files/file_path.h" |
| 9 #include "base/path_service.h" | 9 #include "base/path_service.h" |
| 10 #include "net/base/ev_root_ca_metadata.h" | 10 #include "net/cert/ev_root_ca_metadata.h" |
| 11 #include "net/base/x509_certificate.h" | 11 #include "net/cert/x509_certificate.h" |
| 12 #include "testing/gtest/include/gtest/gtest.h" | 12 #include "testing/gtest/include/gtest/gtest.h" |
| 13 | 13 |
| 14 namespace net { | 14 namespace net { |
| 15 | 15 |
| 16 CertificateList CreateCertificateListFromFile( | 16 CertificateList CreateCertificateListFromFile( |
| 17 const base::FilePath& certs_dir, | 17 const base::FilePath& certs_dir, |
| 18 const std::string& cert_file, | 18 const std::string& cert_file, |
| 19 int format) { | 19 int format) { |
| 20 base::FilePath cert_path = certs_dir.AppendASCII(cert_file); | 20 base::FilePath cert_path = certs_dir.AppendASCII(cert_file); |
| 21 std::string cert_data; | 21 std::string cert_data; |
| (...skipping 26 matching lines...) Expand all Loading... |
| 48 : fingerprint_(fingerprint), | 48 : fingerprint_(fingerprint), |
| 49 ev_root_ca_metadata_(ev_root_ca_metadata) { | 49 ev_root_ca_metadata_(ev_root_ca_metadata) { |
| 50 EXPECT_TRUE(ev_root_ca_metadata->AddEVCA(fingerprint, policy)); | 50 EXPECT_TRUE(ev_root_ca_metadata->AddEVCA(fingerprint, policy)); |
| 51 } | 51 } |
| 52 | 52 |
| 53 ScopedTestEVPolicy::~ScopedTestEVPolicy() { | 53 ScopedTestEVPolicy::~ScopedTestEVPolicy() { |
| 54 EXPECT_TRUE(ev_root_ca_metadata_->RemoveEVCA(fingerprint_)); | 54 EXPECT_TRUE(ev_root_ca_metadata_->RemoveEVCA(fingerprint_)); |
| 55 } | 55 } |
| 56 | 56 |
| 57 } // namespace net | 57 } // namespace net |
| OLD | NEW |