]> granicus.if.org Git - php/commitdiff
add new test
authorAntony Dovgal <tony2001@php.net>
Fri, 19 May 2006 11:15:57 +0000 (11:15 +0000)
committerAntony Dovgal <tony2001@php.net>
Fri, 19 May 2006 11:15:57 +0000 (11:15 +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..5f292bd
--- /dev/null
@@ -0,0 +1,16 @@
+--TEST--
+Bug #29566 (foreach/string handling strangeness)
+--FILE--
+<?php
+$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===