Files
Gumble-Backend/internal/util/oauth2/pkce_test.go
Zane Walker 7e940c83a7
Some checks failed
Build & Test / build-test (push) Has been cancelled
Build & Test / swagger-codegen-cli (push) Has been cancelled
CodeQL / Analyze (go) (push) Has been cancelled
(Feat): Initial Commit
2026-07-03 19:41:31 +05:30

17 lines
488 B
Go

package oauth2_test
import (
"testing"
"allaboutapps.dev/aw/go-starter/internal/util/oauth2"
"github.com/stretchr/testify/assert"
)
func TestGetPKCECodeChallengeS256(t *testing.T) {
verifier := "U7MEZRmshzwIHRIGvF5iy6FLKgTtUHV0Vb0Hpczh6jJ_XZKcQIurow2LvsjG6hx2k57s9Pz8UmCZTvazosnniTM-z6EC.skJlQMGA~8ue3LMiOWdFYTfsLdX8GKol285"
expected := "Jg697bAjhzV1upYvV9R04784OFNVRAZh2IjeFlMJ8bE"
challenge := oauth2.GetPKCECodeChallengeS256(verifier)
assert.Equal(t, expected, challenge)
}