(t *testing.T)
| 106 | } |
| 107 | |
| 108 | func Test_redeemCode(t *testing.T) { |
| 109 | opts := baseTestOptions() |
| 110 | err := validation.Validate(opts) |
| 111 | assert.NoError(t, err) |
| 112 | |
| 113 | proxy, err := NewOAuthProxy(opts, func(string) bool { return true }) |
| 114 | if err != nil { |
| 115 | t.Fatal(err) |
| 116 | } |
| 117 | |
| 118 | req := httptest.NewRequest(http.MethodGet, "/", nil) |
| 119 | _, err = proxy.redeemCode(req, "") |
| 120 | assert.Equal(t, providers.ErrMissingCode, err) |
| 121 | } |
| 122 | |
| 123 | func Test_enrichSession(t *testing.T) { |
| 124 | const ( |
nothing calls this directly
no test coverage detected