From b07fe546fdac6df1b4e0c4d3388534fba3843b05 Mon Sep 17 00:00:00 2001 From: Mariano Cano Date: Thu, 7 Mar 2019 15:58:56 -0800 Subject: [PATCH] Fix types in tests. --- ca/ca_test.go | 3 ++- ca/client_test.go | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/ca/ca_test.go b/ca/ca_test.go index 32701c05..d5fc17f7 100644 --- a/ca/ca_test.go +++ b/ca/ca_test.go @@ -20,6 +20,7 @@ import ( "github.com/smallstep/assert" "github.com/smallstep/certificates/api" "github.com/smallstep/certificates/authority" + "github.com/smallstep/certificates/authority/provisioner" "github.com/smallstep/cli/crypto/keys" "github.com/smallstep/cli/crypto/pemutil" "github.com/smallstep/cli/crypto/randutil" @@ -389,7 +390,7 @@ func TestCAProvisionerEncryptedKey(t *testing.T) { } }, "ok": func(t *testing.T) *ekt { - p := config.AuthorityConfig.Provisioners[2] + p := config.AuthorityConfig.Provisioners[2].(*provisioner.JWK) return &ekt{ ca: ca, kid: p.Key.KeyID, diff --git a/ca/client_test.go b/ca/client_test.go index d82afa31..68fefd09 100644 --- a/ca/client_test.go +++ b/ca/client_test.go @@ -14,7 +14,7 @@ import ( "time" "github.com/smallstep/certificates/api" - "github.com/smallstep/certificates/authority" + "github.com/smallstep/certificates/authority/provisioner" ) const ( @@ -391,7 +391,7 @@ func TestClient_Renew(t *testing.T) { func TestClient_Provisioners(t *testing.T) { ok := &api.ProvisionersResponse{ - Provisioners: []*authority.Provisioner{}, + Provisioners: provisioner.List{}, } internalServerError := api.InternalServerError(fmt.Errorf("Internal Server Error"))