debug and dry-run flags added

This commit is contained in:
Ivan Pedrazas
2016-12-12 14:18:56 +00:00
parent bc616d3b11
commit d572cbc3ee
3 changed files with 59 additions and 15 deletions
+23 -1
View File
@@ -1,6 +1,9 @@
package main
import "testing"
import (
"fmt"
"testing"
)
func TestInitialiseKubeconfig(t *testing.T) {
@@ -21,3 +24,22 @@ func TestInitialiseKubeconfig(t *testing.T) {
initialiseKubeconfig(&plugin.Config, "kubeconfig", "config3.test")
}
func TestGetHelmCommand(t *testing.T) {
plugin := &Plugin{
Config: Config{
APIServer: "http://myapiserver",
Token: "secret-token",
HelmCommand: nil,
Namespace: "default",
SkipTLSVerify: true,
Debug: true,
DryRun: true,
Chart: "./chart/test",
Release: "test-release",
},
}
setHelmCommand(plugin)
fmt.Println(plugin.Config.HelmCommand)
}