addressed review comments

Signed-off-by: tanujd11 <dwiveditanuj41@gmail.com>
This commit is contained in:
tanujd11 2023-12-07 23:28:53 +05:30
parent 28ca4312b3
commit a29a5913d0
5 changed files with 2 additions and 6 deletions

View File

@ -231,7 +231,6 @@ type CertificateSpec struct {
// `--feature-gates=useCertificateRequestNameConstraints=true` option set on both
// the controller and webhook components.
// +optional
// +optional
NameConstraints *NameConstraints `json:"nameConstraints,omitempty"`
}

View File

@ -229,7 +229,6 @@ type CertificateSpec struct {
// `--feature-gates=useCertificateRequestNameConstraints=true` option set on both
// the controller and webhook components.
// +optional
// +optional
NameConstraints *NameConstraints `json:"nameConstraints,omitempty"`
}

View File

@ -206,7 +206,6 @@ type CertificateSpec struct {
// `--feature-gates=useCertificateRequestNameConstraints=true` option set on both
// the controller and webhook components.
// +optional
// +optional
NameConstraints *NameConstraints `json:"nameConstraints,omitempty"`
}

View File

@ -271,7 +271,6 @@ type CertificateSpec struct {
// `--feature-gates=useCertificateRequestNameConstraints=true` option set on both
// the controller and webhook components.
// +optional
// +optional
NameConstraints *NameConstraints `json:"nameConstraints,omitempty"`
}

View File

@ -644,7 +644,6 @@ func TestGenerateCSR(t *testing.T) {
Version: 0,
SignatureAlgorithm: x509.SHA256WithRSA,
PublicKeyAlgorithm: x509.RSA,
Subject: pkix.Name{CommonName: "example.org"},
ExtraExtensions: []pkix.Extension{
{
Id: OIDExtensionKeyUsage,
@ -657,6 +656,7 @@ func TestGenerateCSR(t *testing.T) {
Critical: true,
},
},
RawSubject: subjectGenerator(t, pkix.Name{CommonName: "example.org"}),
},
nameConstraintsFeatureEnabled: true,
},
@ -674,7 +674,7 @@ func TestGenerateCSR(t *testing.T) {
return
}
if !reflect.DeepEqual(got, tt.want) {
t.Errorf("GenerateCSR() got = %v, want %v", got, tt.want)
t.Errorf("GenerateCSR() got = %v, want %v", got, tt.want.ExtraExtensions)
}
})
}