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

Unified Diff: net/cert/internal/path_builder_unittest.cc

Issue 2801813004: Refactor VerifyCertificateChain test data to include a key purpose (Closed)
Patch Set: checkpoint Created 3 years, 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | net/cert/internal/path_builder_verify_certificate_chain_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/cert/internal/path_builder_unittest.cc
diff --git a/net/cert/internal/path_builder_unittest.cc b/net/cert/internal/path_builder_unittest.cc
index ed26c159a67446e9a6943a17b19f6f9f0e7f168c..90ee9c71b6d6ea2abde436241cec06dd32a5e836 100644
--- a/net/cert/internal/path_builder_unittest.cc
+++ b/net/cert/internal/path_builder_unittest.cc
@@ -439,12 +439,15 @@ class PathBuilderKeyRolloverTest : public ::testing::Test {
void SetUp() override {
ParsedCertificateList path;
- bool unused_result;
- std::string unused_errors;
+ VerifyCertChainTest test;
ReadVerifyCertChainTestFromFile(
"net/data/verify_certificate_chain_unittest/key-rollover-oldchain.pem",
- &path, &oldroot_, &time_, &unused_result, &unused_errors);
+ &test);
+ path = test.chain;
+ oldroot_ = test.trust_anchor;
+ time_ = test.time;
mattm 2017/04/06 20:29:34 doesn't need to set oldroot_ and time_ from both c
eroman 2017/04/07 21:41:30 Done.
+
ASSERT_EQ(2U, path.size());
target_ = path[0];
oldintermediate_ = path[1];
@@ -454,7 +457,11 @@ class PathBuilderKeyRolloverTest : public ::testing::Test {
ReadVerifyCertChainTestFromFile(
"net/data/verify_certificate_chain_unittest/"
"key-rollover-longrolloverchain.pem",
- &path, &oldroot_, &time_, &unused_result, &unused_errors);
+ &test);
+ path = test.chain;
+ oldroot_ = test.trust_anchor;
+ time_ = test.time;
+
ASSERT_EQ(4U, path.size());
newintermediate_ = path[1];
newroot_ = path[2];
« no previous file with comments | « no previous file | net/cert/internal/path_builder_verify_certificate_chain_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698