mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-23 19:56:01 +00:00
Fix panic in auth test failure
This commit is contained in:
parent
4a78db6137
commit
22649a19d0
@ -1311,11 +1311,11 @@ func TestWebhookTokenAuthenticator(t *testing.T) {
|
||||
|
||||
func() {
|
||||
resp, err := transport.RoundTrip(req)
|
||||
defer resp.Body.Close()
|
||||
if err != nil {
|
||||
t.Logf("case %v", r)
|
||||
t.Fatalf("unexpected error: %v", err)
|
||||
}
|
||||
defer resp.Body.Close()
|
||||
// Expect all of Alice's actions to at least get past authn/authz.
|
||||
if resp.StatusCode == http.StatusUnauthorized || resp.StatusCode == http.StatusForbidden {
|
||||
t.Logf("case %v", r)
|
||||
|
Loading…
Reference in New Issue
Block a user