make the test succeed
This commit is contained in:
parent
9fcfb1009c
commit
8726fcfa3a
|
@ -29,6 +29,7 @@ func TestCertificateCreation(t *testing.T) {
|
|||
cert_opts := CertificateOptions{
|
||||
// KeyUsage: x509.KeyUsageEncipherOnly | x509.KeyUsageKeyEncipherment | x509.KeyUsageCertSign,
|
||||
SerialNumber: big.NewInt(1),
|
||||
CALength: -1,
|
||||
}
|
||||
|
||||
cert, err := csr.ToCertificate(pk, cert_opts, nil)
|
||||
|
@ -42,6 +43,9 @@ func TestCertificateCreation(t *testing.T) {
|
|||
}
|
||||
|
||||
func fieldsAreSame(data CertificateData, cert *Certificate) bool {
|
||||
if cert == nil {
|
||||
return false
|
||||
}
|
||||
if data.Subject.CommonName != cert.Subject.CommonName {
|
||||
return false
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue