Fixed code formatting issues discovered by verify-gofmt

Kubernetes-commit: 2d21f16c38e704eaaa42d7d583ddd103c16d0d6b
This commit is contained in:
Brian Pursley 2020-02-04 10:16:06 -05:00 committed by Kubernetes Publisher
parent e9f1eb93f4
commit 1777c19079
1 changed files with 15 additions and 15 deletions

View File

@ -101,31 +101,31 @@ func TestPluginPathsAreValid(t *testing.T) {
expectOut string
}{
{
name: "ensure no plugins found if no files begin with kubectl- prefix",
pluginPaths: []string{tempDir},
verifier: newFakePluginPathVerifier(),
pluginFile: func() (*os.File, error) {
name: "ensure no plugins found if no files begin with kubectl- prefix",
pluginPaths: []string{tempDir},
verifier: newFakePluginPathVerifier(),
pluginFile: func() (*os.File, error) {
return ioutil.TempFile(tempDir, "notkubectl-")
},
expectErr: "error: unable to find any kubectl plugins in your PATH\n",
expectErr: "error: unable to find any kubectl plugins in your PATH\n",
},
{
name: "ensure de-duplicated plugin-paths slice",
pluginPaths: []string{tempDir, tempDir},
verifier: newFakePluginPathVerifier(),
pluginFile: func() (*os.File, error) {
name: "ensure de-duplicated plugin-paths slice",
pluginPaths: []string{tempDir, tempDir},
verifier: newFakePluginPathVerifier(),
pluginFile: func() (*os.File, error) {
return ioutil.TempFile(tempDir, "kubectl-")
},
expectOut: "The following compatible plugins are available:",
expectOut: "The following compatible plugins are available:",
},
{
name: "ensure no errors when empty string or blank path are specified",
pluginPaths: []string{tempDir, "", " "},
verifier: newFakePluginPathVerifier(),
pluginFile: func() (*os.File, error) {
name: "ensure no errors when empty string or blank path are specified",
pluginPaths: []string{tempDir, "", " "},
verifier: newFakePluginPathVerifier(),
pluginFile: func() (*os.File, error) {
return ioutil.TempFile(tempDir, "kubectl-")
},
expectOut: "The following compatible plugins are available:",
expectOut: "The following compatible plugins are available:",
},
}