CJohnston079 / obfuscator

0 stars 0 forks source link

`format_xml_data` returns data in the wrong format #19

Closed CJohnston079 closed 4 months ago

CJohnston079 commented 4 months ago

Issue

format_xml_data incorrectly formats xml data. In currently returns xml data in the format:

<data>
    <entry>
        <person>{'name': 'Dale Evans', 'age': '42', 'city': 'Abbieburgh'}</person>
    </entry>
<data>

The expected format is:

<data>
    <entry>
        <person>
            <name>Dale Evans</name>
            <age>42</age>
            <city>Abbieburgh</city>
        </person>
    </entry>
<data>

Proposed resolution

The function has multiple issues, which will require a rewrite from the ground up. The testing suite also failed to catch this error, which was caught by test_obfuscator_returns_expected_value when testing xml input.

CJohnston079 commented 4 months ago

Resolved in 867945962e263a8a25b581a728e52c98fb42fe3a