mirror of
https://github.com/php/php-src.git
synced 2025-01-08 20:17:28 +08:00
fix tests for array/object BC
This commit is contained in:
parent
8f32490ca3
commit
b2cd1a717a
@ -280,23 +280,13 @@ Warning: array_key_exists(): The first argument should be either a string or an
|
||||
bool(false)
|
||||
|
||||
*** Testing operation on objects ***
|
||||
|
||||
Warning: array_key_exists() expects parameter 2 to be array, object given in %s on line %d
|
||||
NULL
|
||||
|
||||
Warning: array_key_exists() expects parameter 2 to be array, object given in %s on line %d
|
||||
NULL
|
||||
|
||||
Warning: array_key_exists() expects parameter 2 to be array, object given in %s on line %d
|
||||
NULL
|
||||
|
||||
Warning: array_key_exists() expects parameter 2 to be array, object given in %s on line %d
|
||||
NULL
|
||||
|
||||
Warning: array_key_exists() expects parameter 2 to be array, object given in %s on line %d
|
||||
NULL
|
||||
bool(false)
|
||||
bool(false)
|
||||
bool(true)
|
||||
bool(false)
|
||||
bool(true)
|
||||
bool(true)
|
||||
|
||||
Warning: array_key_exists() expects parameter 2 to be array, object given in %s on line %d
|
||||
NULL
|
||||
Warning: array_key_exists(): The first argument should be either a string or an integer in %s on line %d
|
||||
bool(false)
|
||||
Done
|
||||
|
@ -52,15 +52,11 @@ echo "Done";
|
||||
|
||||
-- Do not assign a value to $class1->var3 --
|
||||
$key = var1:
|
||||
|
||||
Warning: array_key_exists() expects parameter 2 to be array, object given in %s on line %d
|
||||
NULL
|
||||
bool(true)
|
||||
$key = var3:
|
||||
|
||||
Warning: array_key_exists() expects parameter 2 to be array, object given in %s on line %d
|
||||
NULL
|
||||
bool(true)
|
||||
$class1:
|
||||
object(myClass)#%d (3) {
|
||||
object(myClass)#1 (3) {
|
||||
["var1"]=>
|
||||
string(1) "a"
|
||||
["var2"]=>
|
||||
@ -71,11 +67,9 @@ object(myClass)#%d (3) {
|
||||
|
||||
-- Assign a value to $class2->var3 --
|
||||
$key = var3:
|
||||
|
||||
Warning: array_key_exists() expects parameter 2 to be array, object given in %s on line %d
|
||||
NULL
|
||||
bool(true)
|
||||
$class2:
|
||||
object(myClass)#%d (3) {
|
||||
object(myClass)#2 (3) {
|
||||
["var1"]=>
|
||||
string(1) "x"
|
||||
["var2"]=>
|
||||
|
@ -54,19 +54,13 @@ echo "Done";
|
||||
|
||||
-- Do not assign a value to $class1->var3 --
|
||||
$key = var1:
|
||||
|
||||
Warning: array_key_exists() expects parameter 2 to be array, object given in %s on line %d
|
||||
NULL
|
||||
bool(true)
|
||||
$key = var2:
|
||||
|
||||
Warning: array_key_exists() expects parameter 2 to be array, object given in %s on line %d
|
||||
NULL
|
||||
bool(false)
|
||||
$key = var3:
|
||||
|
||||
Warning: array_key_exists() expects parameter 2 to be array, object given in %s on line %d
|
||||
NULL
|
||||
bool(false)
|
||||
$class1:
|
||||
object(myClass)#%d (3) {
|
||||
object(myClass)#1 (3) {
|
||||
["var1"]=>
|
||||
string(1) "a"
|
||||
["var2":protected]=>
|
||||
@ -77,11 +71,9 @@ object(myClass)#%d (3) {
|
||||
|
||||
-- Assign a value to $class2->var3 --
|
||||
$key = var3:
|
||||
|
||||
Warning: array_key_exists() expects parameter 2 to be array, object given in %s on line %d
|
||||
NULL
|
||||
bool(false)
|
||||
$class2:
|
||||
object(myClass)#%d (3) {
|
||||
object(myClass)#2 (3) {
|
||||
["var1"]=>
|
||||
string(1) "x"
|
||||
["var2":protected]=>
|
||||
|
@ -206,9 +206,7 @@ Warning: array_key_exists() expects parameter 2 to be array, string given in %s
|
||||
NULL
|
||||
|
||||
-- Iteration 22 --
|
||||
|
||||
Warning: array_key_exists() expects parameter 2 to be array, object given in %s on line %d
|
||||
NULL
|
||||
bool(false)
|
||||
|
||||
-- Iteration 23 --
|
||||
|
||||
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -198,8 +198,6 @@ Warning: current() expects parameter 1 to be array, string given in %s on line %
|
||||
NULL
|
||||
|
||||
-- Iteration 21 --
|
||||
|
||||
Warning: current() expects parameter 1 to be array, object given in %s on line %d
|
||||
NULL
|
||||
|
||||
-- Iteration 22 --
|
||||
|
@ -201,9 +201,7 @@ Warning: end() expects parameter 1 to be array, string given in %s on line %d
|
||||
NULL
|
||||
|
||||
-- Iteration 22 --
|
||||
|
||||
Warning: end() expects parameter 1 to be array, object given in %s on line %d
|
||||
NULL
|
||||
string(12) "hello, world"
|
||||
|
||||
-- Iteration 23 --
|
||||
|
||||
|
@ -201,9 +201,7 @@ Warning: key() expects parameter 1 to be array, string given in %s on line %d
|
||||
NULL
|
||||
|
||||
-- Iteration 22 --
|
||||
|
||||
Warning: key() expects parameter 1 to be array, object given in %s on line %d
|
||||
NULL
|
||||
string(4) "var1"
|
||||
|
||||
-- Iteration 23 --
|
||||
|
||||
|
@ -200,9 +200,7 @@ Warning: next() expects parameter 1 to be array, string given in %s on line %d
|
||||
NULL
|
||||
|
||||
-- Iteration 22 --
|
||||
|
||||
Warning: next() expects parameter 1 to be array, object given in %s on line %d
|
||||
NULL
|
||||
bool(false)
|
||||
|
||||
-- Iteration 23 --
|
||||
|
||||
|
@ -200,9 +200,7 @@ Warning: prev() expects parameter 1 to be array, string given in %s on line %d
|
||||
NULL
|
||||
|
||||
-- Iteration 22 --
|
||||
|
||||
Warning: prev() expects parameter 1 to be array, object given in %s on line %d
|
||||
NULL
|
||||
bool(false)
|
||||
|
||||
-- Iteration 23 --
|
||||
|
||||
|
@ -200,9 +200,7 @@ Warning: reset() expects parameter 1 to be array, string given in %s on line %d
|
||||
NULL
|
||||
|
||||
-- Iteration 22 --
|
||||
|
||||
Warning: reset() expects parameter 1 to be array, object given in %s on line %d
|
||||
NULL
|
||||
bool(false)
|
||||
|
||||
-- Iteration 23 --
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user