Skip to content

Commit

Permalink
fix: assertion
Browse files Browse the repository at this point in the history
  • Loading branch information
alnr committed Sep 2, 2024
1 parent 3ddc46f commit 6b39809
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions selfservice/strategy/oidc/strategy_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -774,9 +774,7 @@ func TestStrategy(t *testing.T) {
require.NoError(t, err)
require.NoError(t, res.Body.Close())

// The reason for `invalid_client` here is that the code was already used and the session was already authenticated. The invalid_client
// happens because of the way Golang's OAuth2 library is trying out different auth methods when a token request fails, which obfuscates
// the underlying error.
assertSystemErrorWithMessage(t, res, body, http.StatusInternalServerError, "The authorization code has already been used.")
assert.Contains(t, string(body), "invalid_client", "%s", body)
})
})
Expand Down

0 comments on commit 6b39809

Please sign in to comment.