appease the retry linter (#6629)

This commit is contained in:
R.B. Boyer 2019-10-16 11:39:22 -05:00 committed by GitHub
parent e8ee7c42a3
commit a4c5b8e85c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 5 additions and 7 deletions

View File

@ -339,22 +339,20 @@ func TestLeader_SecondaryCA_FixSigningKeyID_via_IntermediateRefresh(t *testing.T
// isn't a super clean way to watch specifically until it's done than polling
// the CA provider anyway.
retry.Run(t, func(r *retry.R) {
require := require.New(r)
// verify that the root is now corrected
provider, activeRoot := s2.getCAProvider()
require.NotNil(provider)
require.NotNil(activeRoot)
require.NotNil(r, provider)
require.NotNil(r, activeRoot)
activeIntermediate, err := provider.ActiveIntermediate()
require.NoError(err)
require.NoError(r, err)
intermediateCert, err := connect.ParseCert(activeIntermediate)
require.NoError(err)
require.NoError(r, err)
// Force this to be derived just from the root, not the intermediate.
expect := connect.EncodeSigningKeyID(intermediateCert.SubjectKeyId)
require.Equal(expect, activeRoot.SigningKeyID)
require.Equal(r, expect, activeRoot.SigningKeyID)
})
}