def test_example_6_23__node_properties():
    """
    Example 6.23. Node Properties

    Expected:
        %YAML 1.2
        ---
        !!map {
          ? &B1 !!str "foo"
          : !!str "bar",
          ? !!str "baz"
          : *B1,
        }
        
    """

    text = dedent("""
        !!str &a1 "foo":
          !!str bar
        &a2 baz : *a1
        
    """)[1:-1]
    
    expected = None
    
    nodes = parser.parse(text)
    print_nodes(nodes)
    
    assert nodes == expected
def test_example_6_23__node_properties ( ) : text = dedent ( """
        !!str &a1 "foo":
          !!str bar
        &a2 baz : *a1
    """ ) [ 1 : - 1 ] expected = None nodes = parser . parse ( text ) print_nodes ( nodes ) assert nodes == expected
Example 6.23. Node Properties

    Expected:
        %YAML 1.2
        ---
        !!map {
          ? &B1 !!str "foo"
          : !!str "bar",
          ? !!str "baz"
          : *B1,
        }