mirror of
https://github.com/lukaszraczylo/traefikoidc.git
synced 2026-06-05 22:44:17 +00:00
Fix the tests hanging on the open channel.
This commit is contained in:
@@ -266,7 +266,6 @@ func New(ctx context.Context, next http.Handler, config *Config, name string) (h
|
||||
t.jwtVerifier = t
|
||||
t.startTokenCleanup()
|
||||
go t.initializeMetadata(config.ProviderURL)
|
||||
|
||||
return t, nil
|
||||
}
|
||||
|
||||
|
||||
+2
-1
@@ -95,8 +95,9 @@ func (ts *TestSuite) Setup() {
|
||||
httpClient: &http.Client{},
|
||||
exchangeCodeForTokenFunc: ts.exchangeCodeForTokenFunc,
|
||||
extractClaimsFunc: extractClaims,
|
||||
initComplete: make(chan struct{}),
|
||||
}
|
||||
|
||||
close(ts.tOidc.initComplete)
|
||||
ts.tOidc.tokenVerifier = ts.tOidc
|
||||
ts.tOidc.jwtVerifier = ts.tOidc
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user