From 528b99e143e2b0010195038bd30ec695a9773aeb Mon Sep 17 00:00:00 2001
From: guangxuli
Date: Thu, 29 Sep 2016 14:24:58 +0800
Subject: [PATCH] no need to remove file respectively
---
plugin/pkg/client/auth/oidc/oidc_test.go | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/plugin/pkg/client/auth/oidc/oidc_test.go b/plugin/pkg/client/auth/oidc/oidc_test.go
index e3dca0f748e..48bbc5a72b6 100644
--- a/plugin/pkg/client/auth/oidc/oidc_test.go
+++ b/plugin/pkg/client/auth/oidc/oidc_test.go
@@ -45,10 +45,7 @@ func TestNewOIDCAuthProvider(t *testing.T) {
}
cert := path.Join(tempDir, "oidc-cert")
key := path.Join(tempDir, "oidc-key")
-
- defer os.Remove(cert)
- defer os.Remove(key)
- defer os.Remove(tempDir)
+ defer os.RemoveAll(tempDir)
oidctesting.GenerateSelfSignedCert(t, "127.0.0.1", cert, key)
op := oidctesting.NewOIDCProvider(t, "")