function Braintree_Xml_ParserTest::testNullOrEmptyString in Commerce Braintree 7
File
- braintree_php/
tests/ unit/ Xml_ParserTest.php, line 28
Class
Code
function testNullOrEmptyString() {
$xml = <<<XML
<root>
<a_nil_value nil="true"></a_nil_value>
<an_empty_string></an_empty_string>
</root>
XML;
$array = Braintree_Xml::buildArrayFromXml($xml);
$this
->assertEquals(array(
'root' => array(
'aNilValue' => null,
'anEmptyString' => '',
),
), $array);
}