|
|
@ -147,6 +147,19 @@ func TestDependencyUpdateCmd(t *testing.T) {
|
|
|
|
if _, err := os.Stat(expect); err != nil {
|
|
|
|
if _, err := os.Stat(expect); err != nil {
|
|
|
|
t.Fatal(err)
|
|
|
|
t.Fatal(err)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// When using `--untar`, ./charts/*.tgz should not exist
|
|
|
|
|
|
|
|
_, _, err = executeActionCommand(
|
|
|
|
|
|
|
|
fmt.Sprintf("dependency update '%s' --repository-config %s --repository-cache %s --untar", dir(chartname), dir("repositories.yaml"), dir()),
|
|
|
|
|
|
|
|
)
|
|
|
|
|
|
|
|
if err != nil {
|
|
|
|
|
|
|
|
t.Fatal(err)
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
// Make sure the actual file is downloaded and untar
|
|
|
|
|
|
|
|
expect = dir(chartname, "charts/reqtest")
|
|
|
|
|
|
|
|
if _, err := os.Stat(expect); err != nil {
|
|
|
|
|
|
|
|
t.Fatal(err)
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
func TestDependencyUpdateCmd_DoNotDeleteOldChartsOnError(t *testing.T) {
|
|
|
|
func TestDependencyUpdateCmd_DoNotDeleteOldChartsOnError(t *testing.T) {
|
|
|
@ -236,7 +249,6 @@ func TestDependencyUpdateCmd_WithRepoThatWasNotAdded(t *testing.T) {
|
|
|
|
fmt.Sprintf("dependency update '%s' --repository-config %s --repository-cache %s", dir(chartname),
|
|
|
|
fmt.Sprintf("dependency update '%s' --repository-config %s --repository-cache %s", dir(chartname),
|
|
|
|
dir("repositories.yaml"), dir()),
|
|
|
|
dir("repositories.yaml"), dir()),
|
|
|
|
)
|
|
|
|
)
|
|
|
|
|
|
|
|
|
|
|
|
if err != nil {
|
|
|
|
if err != nil {
|
|
|
|
t.Logf("Output: %s", out)
|
|
|
|
t.Logf("Output: %s", out)
|
|
|
|
t.Fatal(err)
|
|
|
|
t.Fatal(err)
|
|
|
|