From 5303f42825cb42e8ec0d4c7c577bf08ea185c4f4 Mon Sep 17 00:00:00 2001 From: Marcus Boerger Date: Sat, 29 Oct 2005 21:01:03 +0000 Subject: [PATCH] - Use var_dump() and fix test expectations --- ext/spl/tests/sxe_001.phpt | 63 +++++++++++++++++++------------------- 1 file changed, 32 insertions(+), 31 deletions(-) diff --git a/ext/spl/tests/sxe_001.phpt b/ext/spl/tests/sxe_001.phpt index 72180d6a1e..c6e6b41d0c 100755 --- a/ext/spl/tests/sxe_001.phpt +++ b/ext/spl/tests/sxe_001.phpt @@ -26,38 +26,39 @@ $xml =<< EOF; -$sxe = simplexml_load_string($xml, 'SimpleXMLIterator'); - -print_r($sxe); +var_dump(simplexml_load_string($xml, 'SimpleXMLIterator')); ?> ===DONE=== ---EXPECT-- -SimpleXMLIterator Object -( - [elem1] => SimpleXMLIterator Object - ( - [comment] => SimpleXMLIterator Object - ( - ) - - [elem2] => SimpleXMLIterator Object - ( - [elem3] => SimpleXMLIterator Object - ( - [elem4] => SimpleXMLIterator Object - ( - [test] => SimpleXMLIterator Object - ( - ) - - ) - - ) - - ) - - ) - -) +--EXPECTF-- +object(SimpleXMLIterator)#%d (2) { + ["@attributes"]=> + array(1) { + ["id"]=> + string(5) "elem1" + } + ["elem1"]=> + object(SimpleXMLIterator)#%d (3) { + ["@attributes"]=> + array(1) { + ["attr1"]=> + string(5) "first" + } + ["comment"]=> + object(SimpleXMLIterator)#%d (0) { + } + ["elem2"]=> + object(SimpleXMLIterator)#%d (1) { + ["elem3"]=> + object(SimpleXMLIterator)#%d (1) { + ["elem4"]=> + object(SimpleXMLIterator)#%d (1) { + ["test"]=> + object(SimpleXMLIterator)#%d (0) { + } + } + } + } + } +} ===DONE=== -- 2.40.0