<document source="test data">
    <system_message level="1" line="1" source="test data" type="INFO">
        <paragraph>
            No directive entry for "perl" in module "Text::Restructured::Directive".
            Trying "perl" as canonical directive name.
    <substitution_definition names="sum">
        5
    <system_message level="2" line="2" source="test data" type="WARNING">
        <paragraph>
            Substitution definition "badsub1" empty or invalid.
        <literal_block xml:space="preserve">
            .. |badsub1| perl:: "A substitution may not have.\n\nTwo paragraphs."
    <system_message level="3" line="3" source="test data" type="ERROR">
        <paragraph>
            Error in "perl" directive within substitution definition: may contain a single paragraph only.
        <literal_block xml:space="preserve">
            perl:: ("Cannot return", "Two strings")
    <system_message level="2" line="3" source="test data" type="WARNING">
        <paragraph>
            Substitution definition "badsub2" empty or invalid.
        <literal_block xml:space="preserve">
            .. |badsub2| perl:: ("Cannot return", "Two strings")
    <system_message level="4" line="2" source="perl directive at test data, line 4" type="SEVERE">
        <paragraph>
            Unexpected section title.
        <literal_block xml:space="preserve">
            Cannot have title
            =================
    <system_message level="2" line="4" source="test data" type="WARNING">
        <paragraph>
            Substitution definition "badsub3" empty or invalid.
        <literal_block xml:space="preserve">
            .. |badsub3| perl:: "Cannot have title\n=================\n"
