diff options
author | andy wharmby <wharmby@php.net> | 2009-08-03 22:40:58 +0000 |
---|---|---|
committer | andy wharmby <wharmby@php.net> | 2009-08-03 22:40:58 +0000 |
commit | cfc417af375bbc7db3684feb7b14fcca0c55a959 (patch) | |
tree | 4048a4a202feae312320114b8b8a46f699888fd3 | |
parent | 6bebbf10864a600d6e44c559349762b564cab88f (diff) | |
download | php-git-cfc417af375bbc7db3684feb7b14fcca0c55a959.tar.gz |
Add missing SKIPIF sections to tests
-rw-r--r-- | ext/simplexml/tests/bug36611.phpt | 6 | ||||
-rw-r--r-- | ext/simplexml/tests/bug40451.phpt | 6 | ||||
-rw-r--r-- | ext/simplexml/tests/bug41175.phpt | 6 | ||||
-rw-r--r-- | ext/simplexml/tests/bug41582.phpt | 6 | ||||
-rw-r--r-- | ext/simplexml/tests/bug41861.phpt | 4 | ||||
-rw-r--r-- | ext/simplexml/tests/bug41867.phpt | 6 | ||||
-rw-r--r-- | ext/simplexml/tests/bug41947.phpt | 6 | ||||
-rw-r--r-- | ext/simplexml/tests/bug42259.phpt | 2 | ||||
-rw-r--r-- | ext/simplexml/tests/bug42369.phpt | 6 | ||||
-rw-r--r-- | ext/simplexml/tests/bug43221.phpt | 7 | ||||
-rw-r--r-- | ext/simplexml/tests/bug44478.phpt | 5 | ||||
-rw-r--r-- | ext/simplexml/tests/bug45553.phpt | 7 | ||||
-rw-r--r-- | ext/simplexml/tests/bug46003.phpt | 7 | ||||
-rw-r--r-- | ext/simplexml/tests/bug46047.phpt | 7 | ||||
-rw-r--r-- | ext/simplexml/tests/bug46048.phpt | 6 |
15 files changed, 67 insertions, 20 deletions
diff --git a/ext/simplexml/tests/bug36611.phpt b/ext/simplexml/tests/bug36611.phpt index 835e926fe5..fdcfd4743c 100644 --- a/ext/simplexml/tests/bug36611.phpt +++ b/ext/simplexml/tests/bug36611.phpt @@ -19,12 +19,12 @@ $xml = simplexml_load_string ($xml_str) ; $val = 1; var_dump($val); -$obj->pos["act_idx"] = $val; +$zml->pos["act_idx"] = $val; var_dump($val) ; -echo "Done\n"; ?> +===DONE=== --EXPECT-- int(1) int(1) -Done +===DONE=== diff --git a/ext/simplexml/tests/bug40451.phpt b/ext/simplexml/tests/bug40451.phpt index 1a499a731d..afd78c769f 100644 --- a/ext/simplexml/tests/bug40451.phpt +++ b/ext/simplexml/tests/bug40451.phpt @@ -1,5 +1,7 @@ --TEST-- Bug #40451 (addAttribute() may crash when used with non-existent child node) +--SKIPIF-- +<?php if (!extension_loaded("simplexml")) print "skip"; ?> --FILE-- <?php @@ -15,8 +17,8 @@ $xml = simplexml_load_string($string); $add = $xml->addChild('Host'); $add->Host->addAttribute('enable', 'true'); -echo "Done\n"; ?> +===DONE=== --EXPECTF-- Warning: SimpleXMLElement::addAttribute(): Unable to locate parent Element in %s on line %d -Done +===DONE=== diff --git a/ext/simplexml/tests/bug41175.phpt b/ext/simplexml/tests/bug41175.phpt index 51181d29c0..db03da977e 100644 --- a/ext/simplexml/tests/bug41175.phpt +++ b/ext/simplexml/tests/bug41175.phpt @@ -1,5 +1,7 @@ --TEST-- Bug #41175 (addAttribute() fails to add an attribute with an empty value) +--SKIPIF-- +<?php if (!extension_loaded("simplexml")) print "skip"; ?> --FILE-- <?php @@ -8,9 +10,9 @@ $xml->addAttribute("src", "foo"); $xml->addAttribute("alt", ""); echo $xml->asXML(); -echo "Done\n"; ?> +===DONE=== --EXPECT-- <?xml version="1.0"?> <img src="foo" alt=""/> -Done
\ No newline at end of file +===DONE===
\ No newline at end of file diff --git a/ext/simplexml/tests/bug41582.phpt b/ext/simplexml/tests/bug41582.phpt index b689607d0c..8733810d71 100644 --- a/ext/simplexml/tests/bug41582.phpt +++ b/ext/simplexml/tests/bug41582.phpt @@ -1,5 +1,7 @@ --TEST-- Bug #41582 (SimpleXML crashes when accessing newly created element) +--SKIPIF-- +<?php if (!extension_loaded("simplexml")) print "skip"; ?> --FILE-- <?php @@ -10,9 +12,9 @@ $xml->movie[]->characters->character[0]->name = 'Miss Coder'; echo($xml->asXml()); -echo "Done\n"; ?> +===DONE=== --EXPECT-- <?xml version="1.0" standalone="yes"?> <collection><movie><characters><character><name>Miss Coder</name></character></characters></movie></collection> -Done +===DONE=== diff --git a/ext/simplexml/tests/bug41861.phpt b/ext/simplexml/tests/bug41861.phpt index 07622ebbd3..087b57058f 100644 --- a/ext/simplexml/tests/bug41861.phpt +++ b/ext/simplexml/tests/bug41861.phpt @@ -1,5 +1,7 @@ --TEST-- Bug #41861 (getNamespaces() returns the namespaces of a node's siblings) + --SKIPIF-- + <?php if (!extension_loaded("simplexml")) print "skip"; ?> --FILE-- <?php @@ -28,6 +30,7 @@ foreach (array(null, '#ns1', '#ns2', '#ns3') as $ns) } } ?> +===DONE=== --EXPECT-- root(recursive): 'root' -- namespaces: #ns1, #ns2, #ns3 root(non-recursive): 'root' -- namespaces: @@ -36,3 +39,4 @@ children(): 'last_node_no_ns' -- namespaces: children(#ns1): 'node1' -- namespaces: #ns1 children(#ns2): 'node2' -- namespaces: #ns2 children(#ns3): 'node3' -- namespaces: #ns3 +===DONE===
\ No newline at end of file diff --git a/ext/simplexml/tests/bug41867.phpt b/ext/simplexml/tests/bug41867.phpt index f530f95dcc..33e2de9e22 100644 --- a/ext/simplexml/tests/bug41867.phpt +++ b/ext/simplexml/tests/bug41867.phpt @@ -1,14 +1,18 @@ --TEST-- Bug #41867 (getName is broken) +--SKIPIF-- +<?php if (!extension_loaded("simplexml")) print "skip"; ?> --FILE-- <?php $a = simplexml_load_string("<a><b><c/></b></a>"); echo $a->getName()."\n"; echo $a->b->getName()."\n"; -echo $a->b->c->getName(); +echo $a->b->c->getName()."\n"; ?> +===DONE=== --EXPECT-- a b c +===DONE=== diff --git a/ext/simplexml/tests/bug41947.phpt b/ext/simplexml/tests/bug41947.phpt index 7af9ff8e76..0b974ce4f5 100644 --- a/ext/simplexml/tests/bug41947.phpt +++ b/ext/simplexml/tests/bug41947.phpt @@ -1,5 +1,7 @@ --TEST-- Bug #41947 (addChild incorrectly registers empty strings as namespaces) +--SKIPIF-- +<?php if (!extension_loaded("simplexml")) print "skip"; ?> --FILE-- <?php $xml = simplexml_load_string('<?xml version="1.0" encoding="utf-8"?><root xmlns:myns="http://myns" />'); @@ -7,8 +9,10 @@ $grandchild = $xml->addChild('child', null, 'http://myns')->addChild('grandchild $gchild = $xml->xpath("//grandchild"); if (count($gchild) > 0) { - echo $gchild[0]; + echo $gchild[0]."\n"; } ?> +===DONE=== --EXPECT-- hello +===DONE=== diff --git a/ext/simplexml/tests/bug42259.phpt b/ext/simplexml/tests/bug42259.phpt index 19c02a577a..3dd2c51f2f 100644 --- a/ext/simplexml/tests/bug42259.phpt +++ b/ext/simplexml/tests/bug42259.phpt @@ -1,6 +1,8 @@ --TEST-- Bug #42259 (SimpleXMLIterator loses ancestry) --SKIPIF-- +<?php if (!extension_loaded("simplexml")) print "skip"; ?> +--SKIPIF-- <?php if (!extension_loaded('simplexml')) print 'skip'; if (!extension_loaded("libxml")) print "skip LibXML not present"; diff --git a/ext/simplexml/tests/bug42369.phpt b/ext/simplexml/tests/bug42369.phpt index e5df81460d..e186770033 100644 --- a/ext/simplexml/tests/bug42369.phpt +++ b/ext/simplexml/tests/bug42369.phpt @@ -1,7 +1,7 @@ --TEST-- Bug #42369 (Implicit conversion to string leaks memory) --SKIPIF-- -<?php if (!extension_loaded('simplexml')) echo 'skip simplexml extension is not loaded'; > +<?php if (!extension_loaded('simplexml')) echo 'skip simplexml extension is not loaded'; ?> --FILE-- <?php $xml = '<?xml version="1.0" encoding="utf-8"?>'; @@ -17,9 +17,9 @@ Bug #42369 (Implicit conversion to string leaks memory) md5($x->x); } - echo 'done' . PHP_EOL; ?> +===DONE=== --EXPECT-- explicit conversion no conversion -done
\ No newline at end of file +===DONE===
\ No newline at end of file diff --git a/ext/simplexml/tests/bug43221.phpt b/ext/simplexml/tests/bug43221.phpt index 6973d091c7..53b6efdccd 100644 --- a/ext/simplexml/tests/bug43221.phpt +++ b/ext/simplexml/tests/bug43221.phpt @@ -1,5 +1,7 @@ --TEST-- Bug #43221 (SimpleXML adding default namespace in addAttribute) +--SKIPIF-- +<?php if (!extension_loaded("simplexml")) print "skip"; ?> --FILE-- <?php $xml = simplexml_load_string('<?xml version="1.0" encoding="utf-8"?><root />'); @@ -9,7 +11,10 @@ $n->addAttribute("c", "d", "http://bar.com"); $n->addAttribute("foo:e", "f", "http://bar.com"); print_r($xml->asXml()); ?> +===DONE=== --EXPECTF-- Warning: SimpleXMLElement::addAttribute(): Attribute requires prefix for namespace in %sbug43221.php on line %d <?xml version="1.0" encoding="utf-8"?> -<root><node xmlns:foo="http://bar.com" a="b" foo:e="f">value</node></root>
\ No newline at end of file +<root><node xmlns:foo="http://bar.com" a="b" foo:e="f">value</node></root> +===DONE=== +
\ No newline at end of file diff --git a/ext/simplexml/tests/bug44478.phpt b/ext/simplexml/tests/bug44478.phpt index 5c21d75c8b..17a26f949b 100644 --- a/ext/simplexml/tests/bug44478.phpt +++ b/ext/simplexml/tests/bug44478.phpt @@ -1,5 +1,7 @@ --TEST-- Bug #44478 (Inconsistent behaviour when assigning new nodes) +--SKIPIF-- +<?php if (!extension_loaded("simplexml")) print "skip"; ?> --FILE-- <?php $xml_element = new simpleXMLElement('<root></root>'); @@ -15,6 +17,7 @@ print $xml_element->node2."\n"; print $xml_element->asXML(); ?> +===DONE=== --EXPECTF-- a & b a & b @@ -22,3 +25,5 @@ a & b a & b <?xml version="1.0"?> <root><node1>a &#38; b</node1><node2>a & b</node2></root> +===DONE=== +
\ No newline at end of file diff --git a/ext/simplexml/tests/bug45553.phpt b/ext/simplexml/tests/bug45553.phpt index 37a46f4276..b355c48696 100644 --- a/ext/simplexml/tests/bug45553.phpt +++ b/ext/simplexml/tests/bug45553.phpt @@ -1,5 +1,7 @@ --TEST-- Bug #45553 (Using XPath to return values for attributes with a namespace does not work) +--SKIPIF-- +<?php if (!extension_loaded("simplexml")) print "skip"; ?> --FILE-- <?php $xml =<<<XML @@ -23,9 +25,12 @@ echo $atts[0] . "\n"; $atts = $x->xpath("/xml/data/@label"); echo $atts[0] . "\n"; ?> +===DONE=== --EXPECTF-- I am A I am a:Nothing I am a:A I am a:Nothing -I am Nothing
\ No newline at end of file +I am Nothing +===DONE=== +
\ No newline at end of file diff --git a/ext/simplexml/tests/bug46003.phpt b/ext/simplexml/tests/bug46003.phpt index a10b018725..712675c097 100644 --- a/ext/simplexml/tests/bug46003.phpt +++ b/ext/simplexml/tests/bug46003.phpt @@ -1,5 +1,7 @@ --TEST-- Bug #46003 (isset on nonexisting nodes return unexpected results) +--SKIPIF-- +<?php if (!extension_loaded("simplexml")) print "skip"; ?> --FILE-- <?php $xml =<<<XML @@ -21,10 +23,13 @@ var_dump(isset($x->o->zz)); var_dump(isset($x->o->text)); var_dump(isset($x->o->xx)); ?> +===DONE=== --EXPECTF-- bool(true) bool(false) bool(true) bool(false) bool(false) -bool(true)
\ No newline at end of file +bool(true) +===DONE=== +
\ No newline at end of file diff --git a/ext/simplexml/tests/bug46047.phpt b/ext/simplexml/tests/bug46047.phpt index 37f31cdeb6..0438154823 100644 --- a/ext/simplexml/tests/bug46047.phpt +++ b/ext/simplexml/tests/bug46047.phpt @@ -1,5 +1,7 @@ --TEST-- Bug #46047 (SimpleXML converts empty nodes into object with nested array) +--SKIPIF-- +<?php if (!extension_loaded("simplexml")) print "skip"; ?> --FILE-- <?php $xml = new SimpleXMLElement('<foo><bar><![CDATA[]]></bar><baz/></foo>', @@ -12,6 +14,7 @@ print_r($xml); $xml = new SimpleXMLElement('<foo><bar/><baz/></foo>'); print_r($xml); ?> +===DONE=== --EXPECTF-- SimpleXMLElement Object ( @@ -45,4 +48,6 @@ SimpleXMLElement Object ( ) -)
\ No newline at end of file +) +===DONE=== +
\ No newline at end of file diff --git a/ext/simplexml/tests/bug46048.phpt b/ext/simplexml/tests/bug46048.phpt index e3eb4f5462..97fc9ed083 100644 --- a/ext/simplexml/tests/bug46048.phpt +++ b/ext/simplexml/tests/bug46048.phpt @@ -1,5 +1,7 @@ --TEST-- Bug #46048 (SimpleXML top-level @attributes not part of iterator) +--SKIPIF-- +<?php if (!extension_loaded("simplexml")) print "skip"; ?> --FILE-- <?php $xml = ' @@ -9,8 +11,8 @@ $xml = ' '; $obj = simplexml_load_string($xml); print_r(get_object_vars($obj)); -echo "Done\n"; ?> +===DONE=== --EXPECT-- Array ( @@ -21,4 +23,4 @@ Array [key] => value ) -Done +===DONE=== |