"value",
"key2" => "value2"
];
$formatter = new XmlFormatter();
$this->assertEquals("\nvaluevalue2\n", $formatter->process($array));
}
public function testObjectFormatter()
{
$object = new SampleModel();
$object->Id = "10";
$object->setName("Joao");
$formatter = new XmlFormatter();
$this->assertEquals("\n10Joao\n", $formatter->process(SerializerObject::instance($object)->serialize()));
$this->assertEquals("\n10Joao\n", $formatter->withRootElement("test")->process($object));
}
public function testObjectList()
{
$object = new ModelList3();
$object->addItem(new ModelGetter(10, "John"));
$object->addItem(new ModelGetter(20, "Doe"));
$formatter = new XmlFormatter();
$this->assertEquals("\n10John20Doe\n", $formatter->withListElement("model")->withListElementSuffix()->process($object));
$formatter = new XmlFormatter();
$this->assertEquals("\n- 10John
- 20Doe
\n", $formatter->process(SerializerObject::instance($object->getCollection())->serialize()));
}
}
__halt_compiler();----SIGNATURE:----g1gOZpk8cIR+XDE04SeQbn2PvmOKaDKdWcA65WGtDGqT4AdS0P9Cxo29rohkqdykvwkKDzNHtxBuZbR3H14Btk+dHN/b5AAuF44cl8cyIpENfbjaW0OeP3silz6F+m9D3JmQsPu8YoEr0jCaSpf+kGB/zhGzKcfLPF5jvq212Jbn2yAFtHTd6fNzHxd3ileVUmp8UoHte/nkyNOdbB6GDyQZh9ekoNviBa8D952s2OpcmLVOZtES+RNylh3Vc49E0NcmXB94PRrjHzAGOHGbLQQN941syTVHNnEFhQDTJiPh8rWd8hmWHPGH3PhHFm6ep+MYb/tmXZbsKHRrDbdGugKTAKoqqB/wkYMYYRsi/Dwnk5Ib32+dxHTkO4Qz4Fyn7eROPq31Oevtnnly63R/W2kvNZaZrmvIbDc4UbPHrP81IhbvnBfJQ3VaGjoQcauNiqDb9h1H59jBBydUNrJICbX61maYDP8979DRx8LfBDqGS4JjkVWulUMoKKn/bgX01kgrgLRbh++rpQU9QNLb4sAAz5h6X23boZ+sydeZDKNLou0L9z8UhIcI3Nf4p0H5WQSdvB7lYaioZMP3CxGAK98LxrAN50aSLUQ3dW24u5WJ4GY8vAgUv/kzOFHlbKJ2+yuQe7hgPoO4/ryktLewsxgR3Bgxkgip7IwRk0srh2Y=----ATTACHMENT:----NDEyNzk1NjI4MjIzMzM3OCAyNzYzODU3OTcwNTcyODE2IDk4OTAwOTIyNzUyNjIwMDI=