// FakeUpdate add testdata to home path func FakeUpdate(home string) { util.EnsureHome(home) ioutil.WriteFile(filepath.Join(home, util.Configfile), []byte(tmpConfigfile), 0755) // absolute path to testdata charts testChartsPath := filepath.Join(HelmRoot, "testdata/charts") // copy testdata charts into cache // mock git clone util.CopyDir(testChartsPath, filepath.Join(home, "cache/charts")) }
func TestEnsureHome(t *testing.T) { tmpHome := test.CreateTmpHome() util.EnsureHome(tmpHome) }
// CheckLocalPrereqs makes sure we have all the tools we need to work with // charts locally func CheckLocalPrereqs(home string) { helm.EnsureHome(home) ensureCommand("git") }