Updating test to remove magic "value" key and instead keep repeating the same key name for unkeyed arrays.
Updating functions to match expected structure. Bit dubious about arrayToXml, though.
Private to protected.