1
0
Fork 0
mirror of https://github.com/pomerium/pomerium.git synced 2025-06-01 10:22:43 +02:00
pomerium/pkg/cryptutil/tls_test.go

14 lines
335 B
Go

package cryptutil
import (
"testing"
"github.com/stretchr/testify/assert"
"github.com/stretchr/testify/require"
)
func TestGetCertificateServerNames(t *testing.T) {
cert, err := GenerateCertificate(nil, "www.example.com")
require.NoError(t, err)
assert.Equal(t, []string{"www.example.com"}, GetCertificateServerNames(cert))
}