]> granicus.if.org Git - php/commitdiff
Add new test
authorMarcus Boerger <helly@php.net>
Tue, 24 Aug 2004 21:35:46 +0000 (21:35 +0000)
committerMarcus Boerger <helly@php.net>
Tue, 24 Aug 2004 21:35:46 +0000 (21:35 +0000)
tests/lang/bug29566.phpt [new file with mode: 0755]

diff --git a/tests/lang/bug29566.phpt b/tests/lang/bug29566.phpt
new file mode 100755 (executable)
index 0000000..7fdd3ff
--- /dev/null
@@ -0,0 +1,16 @@
+--TEST--
+Bug #29566 (foreach/string handling strangeness)
+--FILE--
+<?
+$var="This is a string";
+
+$dummy="";
+unset($dummy);
+
+foreach($var['nosuchkey'] as $v) {
+}
+?>
+===DONE===
+--EXPECTF--
+Warning: Invalid argument supplied for foreach() in %sbug29566.php on line %d
+===DONE===