Skip to content

Commit

Permalink
chore: remove obsolete repo-server unit test (#9559)
Browse files Browse the repository at this point in the history
Signed-off-by: Alexander Matyushentsev <AMatyushentsev@gmail.com>
  • Loading branch information
alexmt authored and crenshaw-dev committed Jun 3, 2022
1 parent b1addf5 commit 867660a
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 92 deletions.
47 changes: 0 additions & 47 deletions reposerver/repository/repository_norace_test.go

This file was deleted.

22 changes: 0 additions & 22 deletions reposerver/repository/repository_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -354,28 +354,6 @@ func TestGenerateJsonnetLibOutside(t *testing.T) {
require.Contains(t, err.Error(), "value file '../../../testdata/jsonnet/vendor' resolved to outside repository root")
}

func TestGenerateHelmChartWithDependencies(t *testing.T) {
service := newService("../..")

cleanup := func() {
_ = os.Remove(filepath.Join("../../util/helm/testdata/dependency", helmDepUpMarkerFile))
_ = os.RemoveAll(filepath.Join("../../util/helm/testdata/dependency", "charts"))
}
cleanup()
defer cleanup()

helmRepo := argoappv1.Repository{Name: "bitnami", Type: "helm", Repo: "https://charts.bitnami.com/bitnami"}
q := apiclient.ManifestRequest{
Repo: &argoappv1.Repository{},
ApplicationSource: &argoappv1.ApplicationSource{
Path: "./util/helm/testdata/dependency",
},
Repos: []*argoappv1.Repository{&helmRepo},
}
res1, err := service.GenerateManifest(context.Background(), &q)
assert.Nil(t, err)
assert.Len(t, res1.Manifests, 10)
}
func TestManifestGenErrorCacheByNumRequests(t *testing.T) {

// Returns the state of the manifest generation cache, by querying the cache for the previously set result
Expand Down
23 changes: 0 additions & 23 deletions util/helm/helm_test.go
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
package helm

import (
"fmt"
"os"
"testing"

"github.com/argoproj/argo-cd/v2/util/io/path"
Expand Down Expand Up @@ -103,27 +101,6 @@ func TestHelmGetParamsValueFilesThatExist(t *testing.T) {
assert.Equal(t, slaveCountParam, "3")
}

func TestHelmDependencyBuild(t *testing.T) {
helmRepos := []HelmRepository{{Name: "bitnami", Repo: "https://charts.bitnami.com/bitnami"}}
chart := "dependency"
clean := func() {
_ = os.RemoveAll("./testdata/dependency/charts")
_ = os.RemoveAll("./testdata/dependency/Chart.lock")
}
clean()
defer clean()
h, err := NewHelmApp(fmt.Sprintf("./testdata/%s", chart), helmRepos, false, "", "", false)
assert.NoError(t, err)
err = h.Init()
assert.NoError(t, err)
_, err = h.Template(&TemplateOpts{Name: "wordpress"})
assert.Error(t, err)
err = h.DependencyBuild()
assert.NoError(t, err)
_, err = h.Template(&TemplateOpts{Name: "wordpress"})
assert.NoError(t, err)
}

func TestHelmTemplateReleaseNameOverwrite(t *testing.T) {
h, err := NewHelmApp("./testdata/redis", nil, false, "", "", false)
assert.NoError(t, err)
Expand Down

0 comments on commit 867660a

Please sign in to comment.