Remove service on termination when exec 'kubectl run' command with flags "--rm" and "--expose"

This commit is contained in:
xiangpengzhao
2017-04-27 16:22:43 +08:00
parent f35f5ef464
commit aef9f38baf
2 changed files with 72 additions and 54 deletions

View File

@@ -337,7 +337,7 @@ func TestGenerateService(t *testing.T) {
}
buff := &bytes.Buffer{}
err := generateService(f, cmd, test.args, test.serviceGenerator, test.params, "namespace", buff)
_, err := generateService(f, cmd, test.args, test.serviceGenerator, test.params, "namespace", buff)
if test.expectErr {
if err == nil {
t.Error("unexpected non-error")