MCPcopy Create free account
hub / github.com/aws-cloudformation/rain / TestGetParentNotFound

Function TestGetParentNotFound

internal/node/node_test.go:12–26  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

10)
11
12func TestGetParentNotFound(t *testing.T) {
13 parent := &yaml.Node{
14 Kind: yaml.DocumentNode,
15 }
16
17 child := &yaml.Node{
18 Kind: yaml.ScalarNode,
19 Value: "Child",
20 }
21
22 pair := node.GetParent(child, parent, nil)
23 if pair.Value != nil {
24 t.Errorf("child should not have been found")
25 }
26}
27
28func TestGetParentFound(t *testing.T) {
29 parent := &yaml.Node{

Callers

nothing calls this directly

Calls 1

GetParentFunction · 0.92

Tested by

no test coverage detected