mirror of
https://github.com/helm/helm.git
synced 2026-05-28 04:35:48 -04:00
fix rebase problems
This commit is contained in:
parent
89ab7555db
commit
a82c19b91a
1 changed files with 6 additions and 8 deletions
|
|
@ -43,22 +43,20 @@ func TestInitCmd(t *testing.T) {
|
|||
defer os.Remove(home)
|
||||
|
||||
var buf bytes.Buffer
|
||||
|
||||
fake := testclient.Fake{}
|
||||
fc := fake.NewSimpleClientset()
|
||||
cmd := &initCmd{
|
||||
out: &buf,
|
||||
home: helmpath.Home(home),
|
||||
kubeClient: fake.Extensions(),
|
||||
kubeClient: fc.Extensions(),
|
||||
namespace: api.NamespaceDefault,
|
||||
}
|
||||
if err := cmd.run(); err != nil {
|
||||
t.Errorf("expected error: %v", err)
|
||||
}
|
||||
|
||||
actions := fake.Actions()
|
||||
if action, ok := actions[0].(testclient.CreateAction); !ok || action.GetResource() != "deployments" {
|
||||
t.Errorf("unexpected action: %v, expected create deployment", actions[0])
|
||||
action := fc.Actions()[0]
|
||||
if !action.Matches("create", "deployments") {
|
||||
t.Errorf("unexpected action: %v, expected create deployment", action)
|
||||
}
|
||||
|
||||
expected := "Tiller (the helm server side component) has been installed into your Kubernetes Cluster."
|
||||
if !strings.Contains(buf.String(), expected) {
|
||||
t.Errorf("expected %q, got %q", expected, buf.String())
|
||||
|
|
|
|||
Loading…
Reference in a new issue