use testify in oauth tests

Signed-off-by: Rui Yang <ruiya@vmware.com>
This commit is contained in:
Rui Yang
2020-10-06 21:04:06 -04:00
parent 9952851cc4
commit 60b8875780
2 changed files with 31 additions and 37 deletions

View File

@@ -220,7 +220,7 @@ func (c *oauthConnector) HandleCallback(s connector.Scopes, r *http.Request) (id
func (c *oauthConnector) addGroupsFromMap(groups map[string]bool, result map[string]interface{}) error {
groupsClaim, ok := result[c.groupsKey].([]interface{})
if !ok {
return errors.New("cant convert to array")
return errors.New("cannot convert to slice")
}
for _, group := range groupsClaim {