From: Felipe Pena Date: Mon, 4 Feb 2008 14:02:01 +0000 (+0000) Subject: Fix tests (new error message) X-Git-Tag: RELEASE_2_0_0a1~632 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=b3153882007106952ddb2e0334171310b31705c1;p=php Fix tests (new error message) --- diff --git a/ext/spl/tests/spl_004.phpt b/ext/spl/tests/spl_004.phpt index 179ba0f7a6..dc630a19b1 100755 --- a/ext/spl/tests/spl_004.phpt +++ b/ext/spl/tests/spl_004.phpt @@ -79,7 +79,7 @@ int(4) Error: Argument 3 passed to iterator_apply() must be an array, integer given Error: iterator_apply() expects parameter 3 to be array, integer given NULL -Error: iterator_apply() expects parameter 2 to be valid callback,%sstring given +Error: iterator_apply() expects parameter 2 to be a valid callback, function 'non_existing_functon' not found or invalid function name NULL Error: iterator_apply() expects at most 3 parameters, 4 given NULL diff --git a/ext/spl/tests/spl_autoload_001.phpt b/ext/spl/tests/spl_autoload_001.phpt index 57cfbb6e82..92a2ca96c0 100755 --- a/ext/spl/tests/spl_autoload_001.phpt +++ b/ext/spl/tests/spl_autoload_001.phpt @@ -134,7 +134,7 @@ TestFunc2(TestClass) %stestclass.class.inc bool(true) ===NOFUNCTION=== -Exception: Function 'unavailable_autoload_function' not found +Exception: Function 'unavailable_autoload_function' not found, (function 'unavailable_autoload_function' not found or invalid function name) ===DONE=== --UEXPECTF-- ===EMPTY=== @@ -165,5 +165,5 @@ TestFunc2(TestClass) %stestclass.class.inc bool(true) ===NOFUNCTION=== -Exception: Function 'unavailable_autoload_function' not found +Exception: Function 'unavailable_autoload_function' not found, (function 'unavailable_autoload_function' not found or invalid function name) ===DONE=== diff --git a/ext/spl/tests/spl_autoload_005.phpt b/ext/spl/tests/spl_autoload_005.phpt index 1f946d9794..8ba7965f80 100755 --- a/ext/spl/tests/spl_autoload_005.phpt +++ b/ext/spl/tests/spl_autoload_005.phpt @@ -50,7 +50,7 @@ catch(Exception $e) ===DONE=== --EXPECTF-- -Exception: Passed array specifies a non static method but no object +Exception: Passed array specifies a non static method but no object (non-static method MyAutoLoader::autoLoad() should not be called statically) MyAutoLoader::autoLoad(TestClass) MyAutoLoader::autoThrow(TestClass) Exception: Unavailable diff --git a/ext/spl/tests/spl_autoload_007.phpt b/ext/spl/tests/spl_autoload_007.phpt index 5c7bcbccc0..00e41cd8bb 100755 --- a/ext/spl/tests/spl_autoload_007.phpt +++ b/ext/spl/tests/spl_autoload_007.phpt @@ -59,16 +59,16 @@ foreach($funcs as $idx => $func) --EXPECTF-- string(22) "MyAutoLoader::notExist" -Function 'MyAutoLoader::notExist' not found +Function 'MyAutoLoader::notExist' not found, (class 'MyAutoLoader' does not have a method 'notexist') string(22) "MyAutoLoader::noAccess" -Function 'MyAutoLoader::noAccess' not callable +Function 'MyAutoLoader::noAccess' not callable, (cannot access protected method MyAutoLoader::noAccess()) string(22) "MyAutoLoader::autoLoad" ok string(22) "MyAutoLoader::dynaLoad" -Function 'MyAutoLoader::dynaLoad' not callable +Function 'MyAutoLoader::dynaLoad' not callable, (non-static method MyAutoLoader::dynaLoad() should not be called statically) array(2) { [0]=> @@ -76,7 +76,7 @@ array(2) { [1]=> string(8) "notExist" } -Passed array does not specify an existing static method +Passed array does not specify an existing static method (class 'MyAutoLoader' does not have a method 'notexist') array(2) { [0]=> @@ -84,7 +84,7 @@ array(2) { [1]=> string(8) "noAccess" } -Passed array does not specify a callable static method +Passed array does not specify a callable static method (cannot access protected method MyAutoLoader::noAccess()) array(2) { [0]=> @@ -100,7 +100,7 @@ array(2) { [1]=> string(8) "dynaLoad" } -Passed array specifies a non static method but no object +Passed array specifies a non static method but no object (non-static method MyAutoLoader::dynaLoad() should not be called statically) array(2) { [0]=> @@ -109,7 +109,7 @@ array(2) { [1]=> string(8) "notExist" } -Passed array does not specify an existing method +Passed array does not specify an existing method (class 'MyAutoLoader' does not have a method 'notexist') array(2) { [0]=> @@ -118,7 +118,7 @@ array(2) { [1]=> string(8) "noAccess" } -Passed array does not specify a callable method +Passed array does not specify a callable method (cannot access protected method MyAutoLoader::noAccess()) array(2) { [0]=> @@ -140,16 +140,16 @@ ok ===DONE=== --UEXPECTF-- unicode(22) "MyAutoLoader::notExist" -Function 'MyAutoLoader::notExist' not found +Function 'MyAutoLoader::notExist' not found, (class 'MyAutoLoader' does not have a method 'notexist') unicode(22) "MyAutoLoader::noAccess" -Function 'MyAutoLoader::noAccess' not callable +Function 'MyAutoLoader::noAccess' not callable, (cannot access protected method MyAutoLoader::noAccess()) unicode(22) "MyAutoLoader::autoLoad" ok unicode(22) "MyAutoLoader::dynaLoad" -Function 'MyAutoLoader::dynaLoad' not callable +Function 'MyAutoLoader::dynaLoad' not callable, (non-static method MyAutoLoader::dynaLoad() should not be called statically) array(2) { [0]=> @@ -157,7 +157,7 @@ array(2) { [1]=> unicode(8) "notExist" } -Passed array does not specify an existing static method +Passed array does not specify an existing static method (class 'MyAutoLoader' does not have a method 'notexist') array(2) { [0]=> @@ -165,7 +165,7 @@ array(2) { [1]=> unicode(8) "noAccess" } -Passed array does not specify a callable static method +Passed array does not specify a callable static method (cannot access protected method MyAutoLoader::noAccess()) array(2) { [0]=> @@ -181,7 +181,7 @@ array(2) { [1]=> unicode(8) "dynaLoad" } -Passed array specifies a non static method but no object +Passed array specifies a non static method but no object (non-static method MyAutoLoader::dynaLoad() should not be called statically) array(2) { [0]=> @@ -190,7 +190,7 @@ array(2) { [1]=> unicode(8) "notExist" } -Passed array does not specify an existing method +Passed array does not specify an existing method (class 'MyAutoLoader' does not have a method 'notexist') array(2) { [0]=> @@ -199,7 +199,7 @@ array(2) { [1]=> unicode(8) "noAccess" } -Passed array does not specify a callable method +Passed array does not specify a callable method (cannot access protected method MyAutoLoader::noAccess()) array(2) { [0]=> diff --git a/ext/spl/tests/spl_autoload_008.phpt b/ext/spl/tests/spl_autoload_008.phpt index 95ab6bd599..369b8303e0 100755 --- a/ext/spl/tests/spl_autoload_008.phpt +++ b/ext/spl/tests/spl_autoload_008.phpt @@ -82,7 +82,7 @@ Exception: Bla int(0) ====2==== string(22) "MyAutoLoader::dynaLoad" -LogicException: Function 'MyAutoLoader::dynaLoad' not callable +LogicException: Function 'MyAutoLoader::dynaLoad' not callable (non-static method MyAutoLoader::dynaLoad() should not be called statically) int(0) ====3==== array(2) { @@ -102,7 +102,7 @@ array(2) { [1]=> string(8) "dynaLoad" } -LogicException: Passed array specifies a non static method but no object +LogicException: Passed array specifies a non static method but no object (non-static method MyAutoLoader::dynaLoad() should not be called statically) int(0) ====5==== array(2) { @@ -144,7 +144,7 @@ Exception: Bla int(0) ====2==== unicode(22) "MyAutoLoader::dynaLoad" -LogicException: Function 'MyAutoLoader::dynaLoad' not callable +LogicException: Function 'MyAutoLoader::dynaLoad' not callable (non-static method MyAutoLoader::dynaLoad() should not be called statically) int(0) ====3==== array(2) { @@ -164,7 +164,7 @@ array(2) { [1]=> unicode(8) "dynaLoad" } -LogicException: Passed array specifies a non static method but no object +LogicException: Passed array specifies a non static method but no object (non-static method MyAutoLoader::dynaLoad() should not be called statically) int(0) ====5==== array(2) {