File tree Expand file tree Collapse file tree 1 file changed +8
-7
lines changed
pkg/bundle/internal/target Expand file tree Collapse file tree 1 file changed +8
-7
lines changed Original file line number Diff line number Diff line change @@ -466,15 +466,16 @@ func Test_ApplyTarget_ConfigMap(t *testing.T) {
466466 },
467467 }
468468
469+ certPool := util .NewCertPool ()
470+ err := certPool .AddCertsFromPEM ([]byte (data ))
471+ assert .NoError (t , err )
472+
469473 spec := trustapi.BundleSpec {
470474 Target : trustapi.BundleTarget {
471475 ConfigMap : & trustapi.TargetTemplate {Key : key },
472476 AdditionalFormats : & trustapi.AdditionalFormats {},
473477 },
474478 }
475- certPool := util .NewCertPool ()
476- err := certPool .AddCertsFromPEM ([]byte (data ))
477- assert .NoError (t , err )
478479 resolvedBundle := source.BundleData {CertPool : certPool }
479480 if tt .withJKS {
480481 spec .Target .AdditionalFormats .JKS = & trustapi.JKS {
@@ -916,16 +917,16 @@ func Test_ApplyTarget_Secret(t *testing.T) {
916917 },
917918 }
918919
920+ certPool := util .NewCertPool ()
921+ err := certPool .AddCertsFromPEM ([]byte (data ))
922+ assert .NoError (t , err )
923+
919924 spec := trustapi.BundleSpec {
920925 Target : trustapi.BundleTarget {
921926 Secret : & trustapi.TargetTemplate {Key : key },
922927 AdditionalFormats : & trustapi.AdditionalFormats {},
923928 },
924929 }
925- certPool := util .NewCertPool ()
926- err := certPool .AddCertsFromPEM ([]byte (data ))
927- assert .NoError (t , err )
928-
929930 resolvedBundle := source.BundleData {CertPool : certPool }
930931 if tt .withJKS {
931932 spec .Target .AdditionalFormats .JKS = & trustapi.JKS {
You can’t perform that action at this time.
0 commit comments