Fixed resolver to correctly identify polymorphic circular references.

Both stripe and k8s are correctly identified now.
This commit is contained in:
Dave Shanley
2022-08-23 14:57:32 -04:00
parent 447430256e
commit 5d07da52b1
10 changed files with 206 additions and 44 deletions

View File

@@ -35,7 +35,7 @@ func TestResolver_ResolveComponents_CircularSpec(t *testing.T) {
assert.NotNil(t, resolver)
circ := resolver.Resolve()
assert.Len(t, circ, 4)
assert.Len(t, circ, 3)
_, err := yaml.Marshal(resolver.resolvedRoot)
assert.NoError(t, err)
@@ -53,7 +53,7 @@ func TestResolver_ResolveComponents_Stripe(t *testing.T) {
assert.NotNil(t, resolver)
circ := resolver.Resolve()
assert.Len(t, circ, 229)
assert.Len(t, circ, 21)
}