diff options
author | Marcus Boerger <helly@php.net> | 2003-11-30 13:57:20 +0000 |
---|---|---|
committer | Marcus Boerger <helly@php.net> | 2003-11-30 13:57:20 +0000 |
commit | c3fddcab622186c9bdbca89a1af7b14df0ba6345 (patch) | |
tree | 92cb0e99af497d3b5fc18a2ab123990831b3bab2 /tests | |
parent | 0091b5ca1dea4f12155c7e80cf38c61e75c08469 (diff) | |
download | php-git-c3fddcab622186c9bdbca89a1af7b14df0ba6345.tar.gz |
Fix tests for E_STRICT and check for E_STRICT in run-tests.php.
Diffstat (limited to 'tests')
-rw-r--r-- | tests/classes/__call_001.phpt | 2 | ||||
-rw-r--r-- | tests/classes/bug23951.phpt | 4 | ||||
-rw-r--r-- | tests/classes/bug24399.phpt | 2 | ||||
-rw-r--r-- | tests/classes/class_example.phpt | 2 | ||||
-rwxr-xr-x | tests/classes/destructor_and_references.phpt | 8 | ||||
-rw-r--r-- | tests/classes/inheritance.phpt | 6 | ||||
-rw-r--r-- | tests/classes/interface_doubled.phpt | 2 | ||||
-rw-r--r-- | tests/classes/interface_implemented.phpt | 2 | ||||
-rw-r--r-- | tests/classes/interface_member.phpt | 2 | ||||
-rw-r--r-- | tests/classes/object_reference_001.phpt | 2 | ||||
-rw-r--r-- | tests/lang/bug21669.phpt | 2 | ||||
-rw-r--r-- | tests/lang/bug21961.phpt | 4 | ||||
-rw-r--r-- | tests/lang/bug22231.phpt | 2 | ||||
-rw-r--r-- | tests/lang/bug22367.phpt | 6 | ||||
-rw-r--r-- | tests/lang/bug22510.phpt | 2 | ||||
-rw-r--r-- | tests/lang/bug23922.phpt | 2 | ||||
-rw-r--r-- | tests/lang/bug24403.phpt | 2 | ||||
-rwxr-xr-x | tests/lang/bug25652.phpt | 2 | ||||
-rw-r--r-- | tests/lang/bug26182.phpt | 2 | ||||
-rw-r--r-- | tests/run-test/test005.phpt | 2 | ||||
-rw-r--r-- | tests/run-test/test008.phpt | 2 | ||||
-rw-r--r-- | tests/run-test/test008a.phpt | 2 |
22 files changed, 31 insertions, 31 deletions
diff --git a/tests/classes/__call_001.phpt b/tests/classes/__call_001.phpt index 9a2306250c..f9708e04f1 100644 --- a/tests/classes/__call_001.phpt +++ b/tests/classes/__call_001.phpt @@ -6,7 +6,7 @@ ZE2 __call() <?php class Caller { - var $x = array(1, 2, 3); + public $x = array(1, 2, 3); function __call($m, $a) { echo "Method $m called:\n"; diff --git a/tests/classes/bug23951.phpt b/tests/classes/bug23951.phpt index 61aa90661e..a49d62f3fe 100644 --- a/tests/classes/bug23951.phpt +++ b/tests/classes/bug23951.phpt @@ -8,13 +8,13 @@ define('FOO2', 2); class A { - var $a_var = array(FOO1=>'foo1_value', FOO2=>'foo2_value'); + public $a_var = array(FOO1=>'foo1_value', FOO2=>'foo2_value'); } class B extends A { - var $b_var = 'foo'; + public $b_var = 'foo'; } diff --git a/tests/classes/bug24399.phpt b/tests/classes/bug24399.phpt index 1c62b5bd4a..fedf8e5d24 100644 --- a/tests/classes/bug24399.phpt +++ b/tests/classes/bug24399.phpt @@ -3,7 +3,7 @@ Bug #24399 (is_subclass_of() crashes when parent class doesn't exist) --FILE-- <?php class dooh { - var $blah; + public $blah; } $d = new dooh; var_dump(is_subclass_of($d, 'dooh')); diff --git a/tests/classes/class_example.phpt b/tests/classes/class_example.phpt index 0e3ae3c338..621958b1bd 100644 --- a/tests/classes/class_example.phpt +++ b/tests/classes/class_example.phpt @@ -7,7 +7,7 @@ Classes general test /* pretty nifty object oriented code! */ class user { - var $first_name,$family_name,$address,$phone_num; + public $first_name,$family_name,$address,$phone_num; function display() { echo "User information\n"; diff --git a/tests/classes/destructor_and_references.phpt b/tests/classes/destructor_and_references.phpt index d2afc2aa2c..b55e7fe94d 100755 --- a/tests/classes/destructor_and_references.phpt +++ b/tests/classes/destructor_and_references.phpt @@ -3,10 +3,10 @@ Destucting and references --FILE-- <?php -class test1 {var $x;}; -class test2 {var $x;}; -class test3 {var $x;}; -class test4 {var $x;}; +class test1 {public $x;}; +class test2 {public $x;}; +class test3 {public $x;}; +class test4 {public $x;}; $o1 = new test1; $o2 = new test2; diff --git a/tests/classes/inheritance.phpt b/tests/classes/inheritance.phpt index d5544a4f77..070ad9147d 100644 --- a/tests/classes/inheritance.phpt +++ b/tests/classes/inheritance.phpt @@ -6,8 +6,8 @@ Classes inheritance test /* Inheritance test. Pretty nifty if I do say so myself! */ class foo { - var $a; - var $b; + public $a; + public $b; function display() { echo "This is class foo\n"; echo "a = ".$this->a."\n"; @@ -19,7 +19,7 @@ class foo { }; class bar extends foo { - var $c; + public $c; function display() { /* alternative display function for class bar */ echo "This is class bar\n"; echo "a = ".$this->a."\n"; diff --git a/tests/classes/interface_doubled.phpt b/tests/classes/interface_doubled.phpt index fa190c767a..dbc23de754 100644 --- a/tests/classes/interface_doubled.phpt +++ b/tests/classes/interface_doubled.phpt @@ -30,7 +30,7 @@ interface if_f extends if_e implements if_a, if_b, if_c, if_d, if_e { class base { function test($class) { - echo "is_a(" . get_class($this) . ", $class) ". (is_a($this, $class) ? "yes\n" : "no\n"); + echo "is_a(" . get_class($this) . ", $class) ". (($this instanceof $class) ? "yes\n" : "no\n"); } } diff --git a/tests/classes/interface_implemented.phpt b/tests/classes/interface_implemented.phpt index 4d101762fc..0f5e5cbe7b 100644 --- a/tests/classes/interface_implemented.phpt +++ b/tests/classes/interface_implemented.phpt @@ -15,7 +15,7 @@ interface if_b extends if_a { class base { function _is_a($sub) { - echo 'is_a('.get_class($this).', '.$sub.') = '.(is_a($this, $sub) ? 'yes' : 'no')."\n"; + echo 'is_a('.get_class($this).', '.$sub.') = '.(($this instanceof $sub) ? 'yes' : 'no')."\n"; } function test() { echo $this->_is_a('base'); diff --git a/tests/classes/interface_member.phpt b/tests/classes/interface_member.phpt index 91ff17af1d..329c0728b5 100644 --- a/tests/classes/interface_member.phpt +++ b/tests/classes/interface_member.phpt @@ -6,7 +6,7 @@ ZE2 An interface cannot have properties <?php interface if_a { - var $member; + public $member; } ?> --EXPECTF-- diff --git a/tests/classes/object_reference_001.phpt b/tests/classes/object_reference_001.phpt index 360d19e10b..74acb5de13 100644 --- a/tests/classes/object_reference_001.phpt +++ b/tests/classes/object_reference_001.phpt @@ -6,7 +6,7 @@ ZE2 object references <?php class Foo { - var $name; + public $name; function Foo() { $this->name = "I'm Foo!\n"; diff --git a/tests/lang/bug21669.phpt b/tests/lang/bug21669.phpt index f81011cf6f..643b0695ee 100644 --- a/tests/lang/bug21669.phpt +++ b/tests/lang/bug21669.phpt @@ -9,7 +9,7 @@ class Test { } class Factory { - var $name = "Test"; + public $name = "Test"; function create() { $obj = new $this->name; /* Parse error */ return $obj; diff --git a/tests/lang/bug21961.phpt b/tests/lang/bug21961.phpt index eb2e8d2ce3..24581d663e 100644 --- a/tests/lang/bug21961.phpt +++ b/tests/lang/bug21961.phpt @@ -7,7 +7,7 @@ Bug #21961 (get_parent_class() segfault) class man { - var $name, $bars; + public $name, $bars; function man() { $this->name = 'Mr. X'; @@ -27,7 +27,7 @@ class man class bar extends man { - var $name; + public $name; function bar($w) { diff --git a/tests/lang/bug22231.phpt b/tests/lang/bug22231.phpt index 91e5b2a44b..84142b01ff 100644 --- a/tests/lang/bug22231.phpt +++ b/tests/lang/bug22231.phpt @@ -3,7 +3,7 @@ Bug #22231 (segfault when returning a global variable by reference) --FILE-- <?php class foo { - var $fubar = 'fubar'; + public $fubar = 'fubar'; } function &foo(){ diff --git a/tests/lang/bug22367.phpt b/tests/lang/bug22367.phpt index acc93e1ef5..5b142b4b00 100644 --- a/tests/lang/bug22367.phpt +++ b/tests/lang/bug22367.phpt @@ -4,7 +4,7 @@ Bug #22367 (weird zval allocation problem) <?php class foo { - var $test = array(0, 1, 2, 3, 4); + public $test = array(0, 1, 2, 3, 4); function a($arg) { var_dump(array_key_exists($arg, $this->test)); @@ -31,8 +31,8 @@ class foo class bar extends foo { - var $i = 0; - var $idx; + public $i = 0; + public $idx; function bar($idx) { $this->idx = $idx; diff --git a/tests/lang/bug22510.phpt b/tests/lang/bug22510.phpt index 24bed43339..5c05a82f30 100644 --- a/tests/lang/bug22510.phpt +++ b/tests/lang/bug22510.phpt @@ -4,7 +4,7 @@ Bug #22510 (segfault among complex references) <?php class foo { - var $list = array(); + public $list = array(); function finalize() { print __CLASS__."::".__FUNCTION__."\n"; diff --git a/tests/lang/bug23922.phpt b/tests/lang/bug23922.phpt index 9d383837a4..1fc6e548ff 100644 --- a/tests/lang/bug23922.phpt +++ b/tests/lang/bug23922.phpt @@ -4,7 +4,7 @@ Bug #23922 (scope doesn't properly propagate into internal functions) <?php class foo { - var $foo = 1; + public $foo = 1; function as_string() { assert('$this->foo == 1'); } diff --git a/tests/lang/bug24403.phpt b/tests/lang/bug24403.phpt index 2acc54cf08..fe99257d3d 100644 --- a/tests/lang/bug24403.phpt +++ b/tests/lang/bug24403.phpt @@ -4,7 +4,7 @@ Bug #24403 (scope doesn't properly propagate into internal functions) <?php class a { - var $a = array(); + public $a = array(); function a() { diff --git a/tests/lang/bug25652.phpt b/tests/lang/bug25652.phpt index cf0cc1a265..09cfc18197 100755 --- a/tests/lang/bug25652.phpt +++ b/tests/lang/bug25652.phpt @@ -8,7 +8,7 @@ Bug #25652 (Calling Global functions dynamically fails from Class scope) } class foo { - var $arr = array('testfunc'); + public $arr = array('testfunc'); function bar () { $this->arr[0]('testvalue'); } diff --git a/tests/lang/bug26182.phpt b/tests/lang/bug26182.phpt index 480d1469a0..7d613f812e 100644 --- a/tests/lang/bug26182.phpt +++ b/tests/lang/bug26182.phpt @@ -1,7 +1,7 @@ --TEST-- Bug #26182 (Object properties created redundantly) --INI-- -error_reporting=2039 +error_reporting=4095 --FILE-- <?php diff --git a/tests/run-test/test005.phpt b/tests/run-test/test005.phpt index 65459f8f86..b54cbc50e6 100644 --- a/tests/run-test/test005.phpt +++ b/tests/run-test/test005.phpt @@ -24,7 +24,7 @@ var_dump($php_errormsg); ?> --EXPECTF-- string(1) "1" -string(4) "2047" +string(4) "4095" string(1) "0" string(1) "1" string(1) "0" diff --git a/tests/run-test/test008.phpt b/tests/run-test/test008.phpt index d595b2592b..14fff59bd8 100644 --- a/tests/run-test/test008.phpt +++ b/tests/run-test/test008.phpt @@ -25,7 +25,7 @@ var_dump($php_errormsg); --EXPECTF-- %s: %sivision by zero in %s on line %d string(1) "1" -string(4) "2047" +string(4) "4095" string(1) "0" string(1) "1" string(1) "0" diff --git a/tests/run-test/test008a.phpt b/tests/run-test/test008a.phpt index 04a3c71168..7916ff2352 100644 --- a/tests/run-test/test008a.phpt +++ b/tests/run-test/test008a.phpt @@ -24,7 +24,7 @@ var_dump($php_errormsg); ?> --EXPECTF-- string(1) "1" -string(4) "2047" +string(4) "4095" string(1) "0" string(1) "1" string(1) "0" |