diff options
| author | mo khan <mo@mokhan.ca> | 2025-04-14 16:24:56 -0600 |
|---|---|---|
| committer | mo khan <mo@mokhan.ca> | 2025-04-14 16:24:56 -0600 |
| commit | 7054f1a7383fab6d2e8c6dac131a0daf85ffdbe7 (patch) | |
| tree | 29fec56903a19801598a8ffb0664be8f8e29648d /app/controllers/sessions/controller_test.go | |
| parent | a8c6e1a4aee4a616cd7c73a39e579d7c9b63d720 (diff) | |
test: add placeholder for missing tests
Diffstat (limited to 'app/controllers/sessions/controller_test.go')
| -rw-r--r-- | app/controllers/sessions/controller_test.go | 19 |
1 files changed, 17 insertions, 2 deletions
diff --git a/app/controllers/sessions/controller_test.go b/app/controllers/sessions/controller_test.go index 5018e0c..d90896e 100644 --- a/app/controllers/sessions/controller_test.go +++ b/app/controllers/sessions/controller_test.go @@ -49,8 +49,8 @@ func TestSessions(t *testing.T) { mux := http.NewServeMux() controller.MountTo(mux) - t.Run("GET /", func(t *testing.T) { - t.Run("Without an authenticated session", func(t *testing.T) { + t.Run("GET /session/new", func(t *testing.T) { + t.Run("without an authenticated session", func(t *testing.T) { t.Run("redirect to the OIDC Provider", func(t *testing.T) { r, w := test.RequestResponse("GET", "/session/new") @@ -69,6 +69,21 @@ func TestSessions(t *testing.T) { assert.Equal(t, cfg.Config.RedirectURL, redirectURL.Query().Get("redirect_uri")) assert.Equal(t, "code", redirectURL.Query().Get("response_type")) }) + + t.Run("generates a CSRF token", func(t *testing.T) {}) + }) + + t.Run("with an active authenicated session", func(t *testing.T) {}) + t.Run("with an expired authenicated session", func(t *testing.T) {}) + }) + + t.Run("GET /session/callback", func(t *testing.T) { + t.Run("with an invalid csrf token", func(t *testing.T) {}) + t.Run("with an invalid authorization code grant", func(t *testing.T) {}) + t.Run("with a valid authorization code grant", func(t *testing.T) { + t.Run("stores the id token in a session cookie", func(t *testing.T) {}) + t.Run("stores the access token in a session cookie", func(t *testing.T) {}) + t.Run("redirects to the homepage", func(t *testing.T) {}) }) }) } |
