15881: Update config keys in tests.
authorTom Clegg <tom@tomclegg.ca>
Mon, 11 May 2020 13:59:20 +0000 (09:59 -0400)
committerTom Clegg <tom@tomclegg.ca>
Mon, 11 May 2020 13:59:20 +0000 (09:59 -0400)
Arvados-DCO-1.1-Signed-off-by: Tom Clegg <tom@tomclegg.ca>

lib/controller/handler_test.go

index f09203f72486739d467b88f28b1d6875bc2f1959..3c7ae3a2d9e5abf2773af742e0bcbc1b2213aea5 100644 (file)
@@ -167,8 +167,9 @@ func (s *HandlerSuite) TestProxyNotFound(c *check.C) {
 }
 
 func (s *HandlerSuite) TestProxyRedirect(c *check.C) {
-       s.cluster.Login.ProviderAppID = "test"
-       s.cluster.Login.ProviderAppSecret = "test"
+       s.cluster.Login.SSO.Enable = true
+       s.cluster.Login.SSO.ProviderAppID = "test"
+       s.cluster.Login.SSO.ProviderAppSecret = "test"
        req := httptest.NewRequest("GET", "https://0.0.0.0:1/login?return_to=foo", nil)
        resp := httptest.NewRecorder()
        s.handler.ServeHTTP(resp, req)
@@ -182,7 +183,8 @@ func (s *HandlerSuite) TestProxyRedirect(c *check.C) {
 }
 
 func (s *HandlerSuite) TestLogoutSSO(c *check.C) {
-       s.cluster.Login.ProviderAppID = "test"
+       s.cluster.Login.SSO.Enable = true
+       s.cluster.Login.SSO.ProviderAppID = "test"
        req := httptest.NewRequest("GET", "https://0.0.0.0:1/logout?return_to=https://example.com/foo", nil)
        resp := httptest.NewRecorder()
        s.handler.ServeHTTP(resp, req)
@@ -197,7 +199,8 @@ func (s *HandlerSuite) TestLogoutGoogle(c *check.C) {
                // Google login N/A
                return
        }
-       s.cluster.Login.GoogleClientID = "test"
+       s.cluster.Login.Google.Enable = true
+       s.cluster.Login.Google.ClientID = "test"
        req := httptest.NewRequest("GET", "https://0.0.0.0:1/logout?return_to=https://example.com/foo", nil)
        resp := httptest.NewRecorder()
        s.handler.ServeHTTP(resp, req)