Make test compilable.

This commit is contained in:
Mariano Cano 2019-11-26 18:47:34 -08:00 committed by max furman
parent f469a6bb38
commit f26103d150

View file

@ -146,7 +146,7 @@ func TestAuthority_authorizeToken(t *testing.T) {
} }
raw, err := jwt.Signed(sig).Claims(cl).CompactSerialize() raw, err := jwt.Signed(sig).Claims(cl).CompactSerialize()
assert.FatalError(t, err) assert.FatalError(t, err)
_, err = _a.authorizeToken(raw) _, err = _a.authorizeToken(context.TODO(), raw)
assert.FatalError(t, err) assert.FatalError(t, err)
return &authorizeTest{ return &authorizeTest{
auth: _a, auth: _a,
@ -234,7 +234,7 @@ func TestAuthority_authorizeToken(t *testing.T) {
t.Run(name, func(t *testing.T) { t.Run(name, func(t *testing.T) {
tc := genTestCase(t) tc := genTestCase(t)
p, err := tc.auth.authorizeToken(tc.ott) p, err := tc.auth.authorizeToken(context.TODO(), tc.ott)
if err != nil { if err != nil {
if assert.NotNil(t, tc.err) { if assert.NotNil(t, tc.err) {
switch v := err.(type) { switch v := err.(type) {