cvs: php-src /ext/simplexml/tests 014.phpt 016.phpt
| From: | Marcus Boerger | Date: | Thu, 18 Dec 2003 13:35:40 +0000 |
| Subject: | cvs: php-src /ext/simplexml/tests 014.phpt 016.phpt | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-25290@lists.php.net to get a copy of this message | ||
helly Thu Dec 18 08:35:40 2003 EDT
Modified files:
/php-src/ext/simplexml/tests 014.phpt 016.phpt
Log:
Update tests to see where they fail now exactly
Index: php-src/ext/simplexml/tests/014.phpt
diff -u php-src/ext/simplexml/tests/014.phpt:1.1 php-src/ext/simplexml/tests/014.phpt:1.2
--- php-src/ext/simplexml/tests/014.phpt:1.1 Wed Dec 17 09:49:10 2003
+++ php-src/ext/simplexml/tests/014.phpt Thu Dec 18 08:35:39 2003
@@ -14,13 +14,16 @@
$people = simplexml_load_string($xml);
var_dump($people->person[0]['name']);
var_dump($people->person[0]['age']);
-$people->person[0]['name'] = "XXX";
-$people->person[0]['age'] = 30;
+$person = $people->person[0];
+$person['name'] = "XXX";
var_dump($people->person[0]['name']);
+$people->person[0]['age'] = 30;
var_dump($people->person[0]['age']);
$people->person[0]['age'] += 5;
var_dump($people->person[0]['age']);
+echo "---Unset:---\n";
unset($people->person[0]['age']);
+echo "---Unset?---\n";
var_dump($people->person[0]['age']);
var_dump(isset($people->person[0]['age']));
echo "---Done---\n";
@@ -31,6 +34,8 @@
string(3) "XXX"
string(2) "30"
string(2) "35"
+---Unset:---
+---Unset?---
NULL
bool(false)
---Done---
Index: php-src/ext/simplexml/tests/016.phpt
diff -u php-src/ext/simplexml/tests/016.phpt:1.1 php-src/ext/simplexml/tests/016.phpt:1.2
--- php-src/ext/simplexml/tests/016.phpt:1.1 Wed Dec 17 09:49:10 2003
+++ php-src/ext/simplexml/tests/016.phpt Thu Dec 18 08:35:39 2003
@@ -12,15 +12,28 @@
$people = simplexml_load_string($xml);
var_dump($people->person['name']);
-var_dump($people->person[0]['name']);
-$people->person[0]['name'] .= "ZZZ";
+$people->person['name'] = $people->person['name'] . 'Foo';
+var_dump($people->person['name']);
+$people->person['name'] .= 'Bar';
var_dump($people->person['name']);
+
+echo "---[0]---\n";
+
+$people = simplexml_load_string($xml);
+var_dump($people->person[0]['name']);
+$people->person[0]['name'] = $people->person[0]['name'] .
'Foo';
+var_dump($people->person[0]['name']);
+$people->person[0]['name'] .= 'Bar';
var_dump($people->person[0]['name']);
+
echo "---Done---\n";
?>
--EXPECT--
string(3) "Joe"
+string(3) "JoeFoo"
+string(3) "JoeFooBar"
+---[0]---
string(3) "Joe"
-string(3) "JoeZZZ"
-string(3) "JoeZZZ"
+string(3) "JoeFoo"
+string(3) "JoeFooBar"
---Done---