MCPcopy
hub / github.com/helm/helm / validateDependencyTree

Function validateDependencyTree

pkg/chart/v2/util/dependencies_test.go:542–553  ·  view source on GitHub ↗
(t *testing.T, c *chart.Chart)

Source from the content-addressed store, hash-verified

540}
541
542func validateDependencyTree(t *testing.T, c *chart.Chart) {
543 t.Helper()
544 for _, dependency := range c.Dependencies() {
545 if dependency.Parent() != c {
546 if dependency.Parent() != c {
547 t.Fatalf("dependency chart %s has wrong parent, expected %s but got %s", dependency.Name(), c.Name(), dependency.Parent().Name())
548 }
549 }
550 // recurse entire tree
551 validateDependencyTree(t, dependency)
552 }
553}
554
555func TestChartWithDependencyAliasedTwiceAndDoublyReferencedSubDependency(t *testing.T) {
556 c := loadChart(t, "testdata/chart-with-dependency-aliased-twice")

Calls 5

HelperMethod · 0.80
FatalfMethod · 0.80
DependenciesMethod · 0.65
NameMethod · 0.65
ParentMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…