Skip to content

Commit

Permalink
Merge pull request kubernetes#9782 from andronat/9578_TestCreateClean…
Browse files Browse the repository at this point in the history
…WithPrefix

TestCreateCleanWithPrefix was failing if env variables existed
  • Loading branch information
rjnagal committed Jul 10, 2015
2 parents 161b9c8 + 530369c commit ebc11e1
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion pkg/client/clientcmd/client_config_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -177,9 +177,12 @@ func TestCreateCleanWithPrefix(t *testing.T) {
{"anything.com:8080", "anything.com:8080", ""},
{"anything.com", "anything.com", ""},
{"anything", "anything", ""},
{"", "http://localhost:8080", ""},
}

// WARNING: EnvVarCluster.Server is set during package loading time and can not be overriden by os.Setenv inside this test
EnvVarCluster.Server = ""
tt = append(tt, struct{ server, host, prefix string }{"", "http://localhost:8080", ""})

for _, tc := range tt {
config := createValidTestConfig()

Expand Down

0 comments on commit ebc11e1

Please sign in to comment.