From bb678c07b589b18609b46a08ce098167d44761f0 Mon Sep 17 00:00:00 2001 From: Marcus Boerger Date: Sun, 18 Jan 2004 15:14:03 +0000 Subject: [PATCH] Use external files only in 001.phpt & tests for bugs --- ext/simplexml/tests/002.phpt | 19 ++++++++++++++++++- ext/simplexml/tests/003.phpt | 23 ++++++++++++++++++++++- ext/simplexml/tests/003.xml | 19 ------------------- ext/simplexml/tests/007.phpt | 19 ++++++++++++++++++- ext/simplexml/tests/008.phpt | 21 ++++++++++++++++++++- ext/simplexml/tests/010.phpt | 24 ++++++++++++++++++++---- 6 files changed, 98 insertions(+), 27 deletions(-) delete mode 100755 ext/simplexml/tests/003.xml diff --git a/ext/simplexml/tests/002.phpt b/ext/simplexml/tests/002.phpt index c5cb2323ff1..009101adb08 100644 --- a/ext/simplexml/tests/002.phpt +++ b/ext/simplexml/tests/002.phpt @@ -5,7 +5,24 @@ SimpleXML and clone --FILE-- + + + + + + + + + + + + + +EOF; + +$sxe = simplexml_load_string($xml); $copy = $sxe->__clone(); diff --git a/ext/simplexml/tests/003.phpt b/ext/simplexml/tests/003.phpt index 907b166a0b5..0924fd044fb 100755 --- a/ext/simplexml/tests/003.phpt +++ b/ext/simplexml/tests/003.phpt @@ -5,7 +5,28 @@ SimpleXML and Entities --FILE-- + +]> + + Plain text. + + + + + &included-entity; + + + + + + + +EOF; + +$sxe = simplexml_load_string($xml); print_r($sxe); diff --git a/ext/simplexml/tests/003.xml b/ext/simplexml/tests/003.xml deleted file mode 100755 index 751921b49e7..00000000000 --- a/ext/simplexml/tests/003.xml +++ /dev/null @@ -1,19 +0,0 @@ - - -%incent; -]> - - Plain text. - - - - - &included-entity; - - - - - - - \ No newline at end of file diff --git a/ext/simplexml/tests/007.phpt b/ext/simplexml/tests/007.phpt index c7f3fc18492..d41c84bdebb 100755 --- a/ext/simplexml/tests/007.phpt +++ b/ext/simplexml/tests/007.phpt @@ -5,7 +5,24 @@ SimpleXML and attributes --FILE-- + + + + + + + + + + + + + +EOF; + +$sxe = simplexml_load_string($xml); echo "===Property===\n"; var_dump($sxe->elem1); diff --git a/ext/simplexml/tests/008.phpt b/ext/simplexml/tests/008.phpt index 1726726a1a8..68b6f39351c 100644 --- a/ext/simplexml/tests/008.phpt +++ b/ext/simplexml/tests/008.phpt @@ -4,7 +4,26 @@ SimpleXML and XPath --FILE-- + + + + + + + + + + + + + +EOF; + +$sxe = simplexml_load_string($xml); + var_dump($sxe->xpath("elem1/elem2/elem3/elem4")); var_dump($sxe->xpath("***")); ?> diff --git a/ext/simplexml/tests/010.phpt b/ext/simplexml/tests/010.phpt index 628c9450982..20e2f89a268 100644 --- a/ext/simplexml/tests/010.phpt +++ b/ext/simplexml/tests/010.phpt @@ -9,13 +9,29 @@ class simplexml_inherited extends simplexml_element { } -$sxe = simplexml_load_file(dirname(__FILE__).'/sxe.xml', 'simplexml_inherited'); +$xml =<< + + + + + + + + + + + + + +EOF; + +$sxe = simplexml_load_string($xml, 'simplexml_inherited'); print_r($sxe); -echo "---Done---\n"; - ?> +===DONE=== --EXPECT-- simplexml_inherited Object ( @@ -44,4 +60,4 @@ simplexml_inherited Object ) ) ----Done--- +===DONE===