diff options
author | Peter Kokot <peterkokot@gmail.com> | 2018-10-14 17:45:48 +0200 |
---|---|---|
committer | Peter Kokot <peterkokot@gmail.com> | 2018-10-14 19:45:12 +0200 |
commit | 782352c54ad69c517e3c32b0dd2c25d74842647a (patch) | |
tree | 220bdc1e814e9f44b3578d49b3f239a3fdefa1d0 /tests | |
parent | 604d4bdae5037e021c1f9d35f08cbeddd610d84c (diff) | |
download | php-git-782352c54ad69c517e3c32b0dd2c25d74842647a.tar.gz |
Trim trailing whitespace in *.phpt
Diffstat (limited to 'tests')
375 files changed, 902 insertions, 902 deletions
diff --git a/tests/basic/003.phpt b/tests/basic/003.phpt index 43d3be1d9e..fb906e051d 100644 --- a/tests/basic/003.phpt +++ b/tests/basic/003.phpt @@ -5,7 +5,7 @@ a=Hello+World --GET-- b=Hello+Again+World&c=Hi+Mom --FILE-- -<?php +<?php error_reporting(0); echo "post-a=({$_POST['a']}) get-b=({$_GET['b']}) get-c=({$_GET['c']})"?> --EXPECT-- diff --git a/tests/basic/004.phpt b/tests/basic/004.phpt index c381e5009f..4225c105b5 100644 --- a/tests/basic/004.phpt +++ b/tests/basic/004.phpt @@ -3,7 +3,7 @@ Two variables in POST data --POST-- a=Hello+World&b=Hello+Again+World --FILE-- -<?php +<?php error_reporting(0); echo "{$_POST['a']} {$_POST['b']}" ?> --EXPECT-- diff --git a/tests/basic/005.phpt b/tests/basic/005.phpt index 742e0ca4b1..230ba42bb1 100644 --- a/tests/basic/005.phpt +++ b/tests/basic/005.phpt @@ -3,7 +3,7 @@ Three variables in POST data --POST-- a=Hello+World&b=Hello+Again+World&c=1 --FILE-- -<?php +<?php error_reporting(0); echo "{$_POST['a']} {$_POST['b']} {$_POST['c']}"?> --EXPECT-- diff --git a/tests/basic/011.phpt b/tests/basic/011.phpt index 79256746fe..b5c769d9bd 100644 --- a/tests/basic/011.phpt +++ b/tests/basic/011.phpt @@ -5,7 +5,7 @@ register_argc_argv=1 --GET-- ab+cd+ef+123+test --FILE-- -<?php +<?php $argc = $_SERVER['argc']; $argv = $_SERVER['argv']; diff --git a/tests/basic/012.phpt b/tests/basic/012.phpt index 5c10c7c222..038d4beff9 100644 --- a/tests/basic/012.phpt +++ b/tests/basic/012.phpt @@ -8,7 +8,7 @@ variables_order=GPS --ARGS-- ab cd ef 123 test --FILE-- -<?php +<?php $argc = $_SERVER['argc']; $argv = $_SERVER['argv']; diff --git a/tests/basic/013.phpt b/tests/basic/013.phpt index 376cc06dd4..0cd81a7185 100644 --- a/tests/basic/013.phpt +++ b/tests/basic/013.phpt @@ -4,7 +4,7 @@ POST Method test and arrays a[]=1 --FILE-- <?php -var_dump($_POST['a']); +var_dump($_POST['a']); ?> --EXPECT-- array(1) { diff --git a/tests/basic/014.phpt b/tests/basic/014.phpt index 7288c44a92..1282aad3e4 100644 --- a/tests/basic/014.phpt +++ b/tests/basic/014.phpt @@ -4,7 +4,7 @@ POST Method test and arrays - 2 a[]=1&a[]=1 --FILE-- <?php -var_dump($_POST['a']); +var_dump($_POST['a']); ?> --EXPECT-- array(2) { diff --git a/tests/basic/015.phpt b/tests/basic/015.phpt index eecbaf1302..c74e1e414d 100644 --- a/tests/basic/015.phpt +++ b/tests/basic/015.phpt @@ -1,10 +1,10 @@ --TEST-- -POST Method test and arrays - 3 +POST Method test and arrays - 3 --POST-- a[]=1&a[0]=5 --FILE-- <?php -var_dump($_POST['a']); +var_dump($_POST['a']); ?> --EXPECT-- array(1) { diff --git a/tests/basic/016.phpt b/tests/basic/016.phpt index b34fd1b1dc..7c81444518 100644 --- a/tests/basic/016.phpt +++ b/tests/basic/016.phpt @@ -1,10 +1,10 @@ --TEST-- -POST Method test and arrays - 4 +POST Method test and arrays - 4 --POST-- a[a]=1&a[b]=3 --FILE-- <?php -var_dump($_POST['a']); +var_dump($_POST['a']); ?> --EXPECT-- array(2) { diff --git a/tests/basic/017.phpt b/tests/basic/017.phpt index d514726d18..ca0a2d6491 100644 --- a/tests/basic/017.phpt +++ b/tests/basic/017.phpt @@ -1,10 +1,10 @@ --TEST-- -POST Method test and arrays - 5 +POST Method test and arrays - 5 --POST-- a[]=1&a[a]=1&a[b]=3 --FILE-- <?php -var_dump($_POST['a']); +var_dump($_POST['a']); ?> --EXPECT-- array(3) { diff --git a/tests/basic/018.phpt b/tests/basic/018.phpt index 45996b2fe3..93bca86da1 100644 --- a/tests/basic/018.phpt +++ b/tests/basic/018.phpt @@ -1,11 +1,11 @@ --TEST-- -POST Method test and arrays - 6 +POST Method test and arrays - 6 --POST-- a[][]=1&a[][]=3&b[a][b][c]=1&b[a][b][d]=1 --FILE-- <?php -var_dump($_POST['a']); -var_dump($_POST['b']); +var_dump($_POST['a']); +var_dump($_POST['b']); ?> --EXPECT-- array(2) { diff --git a/tests/basic/019.phpt b/tests/basic/019.phpt index 3bece247a0..0c90c4907a 100644 --- a/tests/basic/019.phpt +++ b/tests/basic/019.phpt @@ -1,10 +1,10 @@ --TEST-- -POST Method test and arrays - 7 +POST Method test and arrays - 7 --POST-- a[]=1&a[]]=3&a[[]=4 --FILE-- <?php -var_dump($_POST['a']); +var_dump($_POST['a']); ?> --EXPECT-- array(3) { diff --git a/tests/basic/020.phpt b/tests/basic/020.phpt index c94a60407b..3a4d7f455b 100644 --- a/tests/basic/020.phpt +++ b/tests/basic/020.phpt @@ -1,10 +1,10 @@ --TEST-- -POST Method test and arrays - 8 +POST Method test and arrays - 8 --POST-- a[a[]]=1&a[b[]]=3 --FILE-- <?php -var_dump($_POST['a']); +var_dump($_POST['a']); ?> --EXPECT-- array(2) { diff --git a/tests/basic/bug45986.phpt b/tests/basic/bug45986.phpt index 33c3f27eac..e63b1b3906 100644 --- a/tests/basic/bug45986.phpt +++ b/tests/basic/bug45986.phpt @@ -3,7 +3,7 @@ Bug #45986 (wrong error message for a non existent file on rename) --CREDITS-- Sebastian Schürmann sebs@php.net -Testfest 2009 Munich +Testfest 2009 Munich --FILE-- <?php rename('foo', 'bar'); diff --git a/tests/basic/bug67198.phpt b/tests/basic/bug67198.phpt index 9e2e224509..4c2322b6de 100644 --- a/tests/basic/bug67198.phpt +++ b/tests/basic/bug67198.phpt @@ -4,7 +4,7 @@ php://input is empty when enable_post_data_reading=Off allow_url_fopen=1 --SKIPIF-- <?php -include __DIR__."/../../sapi/cli/tests/skipif.inc"; +include __DIR__."/../../sapi/cli/tests/skipif.inc"; ?> --FILE-- <?php diff --git a/tests/basic/timeout_variation_0.phpt b/tests/basic/timeout_variation_0.phpt index 4b39ae31dd..adc8e6b7cf 100644 --- a/tests/basic/timeout_variation_0.phpt +++ b/tests/basic/timeout_variation_0.phpt @@ -1,7 +1,7 @@ --TEST-- Timeout within while loop --SKIPIF-- -<?php +<?php if (getenv("SKIP_SLOW_TESTS")) die("skip slow test"); ?> --FILE-- @@ -11,7 +11,7 @@ include dirname(__FILE__) . DIRECTORY_SEPARATOR . "timeout_config.inc"; set_time_limit($t); -while (1) { +while (1) { busy_wait(1); } diff --git a/tests/basic/timeout_variation_1.phpt b/tests/basic/timeout_variation_1.phpt index 28699dcbc4..51568a7492 100644 --- a/tests/basic/timeout_variation_1.phpt +++ b/tests/basic/timeout_variation_1.phpt @@ -1,7 +1,7 @@ --TEST-- Timeout within function --SKIPIF-- -<?php +<?php if (getenv("SKIP_SLOW_TESTS")) die("skip slow test"); ?> --FILE-- @@ -11,8 +11,8 @@ include dirname(__FILE__) . DIRECTORY_SEPARATOR . "timeout_config.inc"; set_time_limit($t); -function hello ($t) { - echo "call"; +function hello ($t) { + echo "call"; busy_wait($t*2); } diff --git a/tests/basic/timeout_variation_10.phpt b/tests/basic/timeout_variation_10.phpt index 373be27b3d..030deaf389 100644 --- a/tests/basic/timeout_variation_10.phpt +++ b/tests/basic/timeout_variation_10.phpt @@ -1,7 +1,7 @@ --TEST-- Timeout within shutdown function, variation --SKIPIF-- -<?php +<?php if (getenv("SKIP_SLOW_TESTS")) die("skip slow test"); ?> --FILE-- diff --git a/tests/basic/timeout_variation_2.phpt b/tests/basic/timeout_variation_2.phpt index 5a549500cf..24574e9c5f 100644 --- a/tests/basic/timeout_variation_2.phpt +++ b/tests/basic/timeout_variation_2.phpt @@ -1,7 +1,7 @@ --TEST-- Timeout within array_walk --SKIPIF-- -<?php +<?php if (getenv("SKIP_SLOW_TESTS")) die("skip slow test"); ?> --FILE-- @@ -12,7 +12,7 @@ include dirname(__FILE__) . DIRECTORY_SEPARATOR . "timeout_config.inc"; set_time_limit($t); function cb(&$i, $k, $p) -{ +{ busy_wait(1); } diff --git a/tests/basic/timeout_variation_3.phpt b/tests/basic/timeout_variation_3.phpt index 1dc169c67b..795ad6505d 100644 --- a/tests/basic/timeout_variation_3.phpt +++ b/tests/basic/timeout_variation_3.phpt @@ -1,7 +1,7 @@ --TEST-- Timeout within eval --SKIPIF-- -<?php +<?php if (getenv("SKIP_SLOW_TESTS")) die("skip slow test"); ?> --FILE-- @@ -11,8 +11,8 @@ include dirname(__FILE__) . DIRECTORY_SEPARATOR . "timeout_config.inc"; set_time_limit($t); -function hello ($t) { - echo "call", PHP_EOL; +function hello ($t) { + echo "call", PHP_EOL; busy_wait($t*2); } diff --git a/tests/basic/timeout_variation_4.phpt b/tests/basic/timeout_variation_4.phpt index 19ebf585a9..7a334fd544 100644 --- a/tests/basic/timeout_variation_4.phpt +++ b/tests/basic/timeout_variation_4.phpt @@ -1,7 +1,7 @@ --TEST-- Timeout within call_user_func --SKIPIF-- -<?php +<?php if (getenv("SKIP_SLOW_TESTS")) die("skip slow test"); ?> --FILE-- @@ -11,8 +11,8 @@ include dirname(__FILE__) . DIRECTORY_SEPARATOR . "timeout_config.inc"; set_time_limit($t); -function hello ($t) { - echo "call", PHP_EOL; +function hello ($t) { + echo "call", PHP_EOL; busy_wait($t*2); } diff --git a/tests/basic/timeout_variation_5.phpt b/tests/basic/timeout_variation_5.phpt index 1c28c00ac9..c3b71e89ab 100644 --- a/tests/basic/timeout_variation_5.phpt +++ b/tests/basic/timeout_variation_5.phpt @@ -1,7 +1,7 @@ --TEST-- Timeout within function containing exception --SKIPIF-- -<?php +<?php if (getenv("SKIP_SLOW_TESTS")) die("skip slow test"); ?> --FILE-- @@ -11,7 +11,7 @@ include dirname(__FILE__) . DIRECTORY_SEPARATOR . "timeout_config.inc"; set_time_limit($t); -function f($t) { +function f($t) { echo "call"; busy_wait($t*2); throw new Exception("never reached here"); diff --git a/tests/basic/timeout_variation_6.phpt b/tests/basic/timeout_variation_6.phpt index fb3c3a7aca..c172625f5d 100644 --- a/tests/basic/timeout_variation_6.phpt +++ b/tests/basic/timeout_variation_6.phpt @@ -1,7 +1,7 @@ --TEST-- Timeout within function trowing exception before timeout reached --SKIPIF-- -<?php +<?php if (getenv("SKIP_SLOW_TESTS")) die("skip slow test"); ?> --FILE-- @@ -11,7 +11,7 @@ include dirname(__FILE__) . DIRECTORY_SEPARATOR . "timeout_config.inc"; set_time_limit($t); -function f($t) { +function f($t) { echo "call"; busy_wait($t-1); throw new Exception("exception before timeout"); diff --git a/tests/basic/timeout_variation_7.phpt b/tests/basic/timeout_variation_7.phpt index e642a33a4e..df8f897550 100644 --- a/tests/basic/timeout_variation_7.phpt +++ b/tests/basic/timeout_variation_7.phpt @@ -1,7 +1,7 @@ --TEST-- Timeout within for loop --SKIPIF-- -<?php +<?php if (getenv("SKIP_SLOW_TESTS")) die("skip slow test"); ?> --FILE-- @@ -11,7 +11,7 @@ include dirname(__FILE__) . DIRECTORY_SEPARATOR . "timeout_config.inc"; set_time_limit($t); -for ($i = 0; $i < 42; $i++) { +for ($i = 0; $i < 42; $i++) { busy_wait(1); } diff --git a/tests/basic/timeout_variation_8.phpt b/tests/basic/timeout_variation_8.phpt index 15c9777f2c..d0a8861700 100644 --- a/tests/basic/timeout_variation_8.phpt +++ b/tests/basic/timeout_variation_8.phpt @@ -1,7 +1,7 @@ --TEST-- Timeout within foreach loop --SKIPIF-- -<?php +<?php if (getenv("SKIP_SLOW_TESTS")) die("skip slow test"); ?> --FILE-- @@ -11,7 +11,7 @@ include dirname(__FILE__) . DIRECTORY_SEPARATOR . "timeout_config.inc"; set_time_limit($t); -foreach (range(0, 42) as $i) { +foreach (range(0, 42) as $i) { busy_wait(1); } diff --git a/tests/basic/timeout_variation_9.phpt b/tests/basic/timeout_variation_9.phpt index 133fdf6daa..390d29b0c0 100644 --- a/tests/basic/timeout_variation_9.phpt +++ b/tests/basic/timeout_variation_9.phpt @@ -1,7 +1,7 @@ --TEST-- Timeout within shutdown function --SKIPIF-- -<?php +<?php if (getenv("SKIP_SLOW_TESTS")) die("skip slow test"); ?> --FILE-- diff --git a/tests/classes/__call_001.phpt b/tests/classes/__call_001.phpt index be2d0248cc..a70041ae16 100644 --- a/tests/classes/__call_001.phpt +++ b/tests/classes/__call_001.phpt @@ -5,7 +5,7 @@ ZE2 __call() class Caller { public $x = array(1, 2, 3); - + function __call($m, $a) { echo "Method $m called:\n"; var_dump($a); diff --git a/tests/classes/__call_003.phpt b/tests/classes/__call_003.phpt index 9ecc0701f0..30662add36 100644 --- a/tests/classes/__call_003.phpt +++ b/tests/classes/__call_003.phpt @@ -1,5 +1,5 @@ --TEST-- -Force pass-by-reference to __call +Force pass-by-reference to __call --FILE-- <?php class C @@ -9,16 +9,16 @@ Force pass-by-reference to __call $values[0][0] = 'changed'; } } - + $a = array('original'); - + $b = array('original'); $hack =& $b[0]; - + $c = new C; $c->f($a); $c->f($b); - + var_dump($a, $b); ?> --EXPECT-- diff --git a/tests/classes/__call_004.phpt b/tests/classes/__call_004.phpt index a9997bf132..ca980c65f0 100644 --- a/tests/classes/__call_004.phpt +++ b/tests/classes/__call_004.phpt @@ -14,7 +14,7 @@ class B extends A { echo "In " . __METHOD__ . "($strMethod, array(" . implode(',',$arrArgs) . "))\n"; var_dump($this); } - + function test() { A::test1(1,'a'); B::test2(1,'a'); diff --git a/tests/classes/__call_005.phpt b/tests/classes/__call_005.phpt index 6e1584878e..33c4df8e49 100644 --- a/tests/classes/__call_005.phpt +++ b/tests/classes/__call_005.phpt @@ -1,5 +1,5 @@ --TEST-- -When __call() is invoked via ::, ensure private implementation of __call() in superclass is accessed without error. +When __call() is invoked via ::, ensure private implementation of __call() in superclass is accessed without error. --FILE-- <?php class A { diff --git a/tests/classes/__call_006.phpt b/tests/classes/__call_006.phpt index c3937393fd..e6efdefe9e 100644 --- a/tests/classes/__call_006.phpt +++ b/tests/classes/__call_006.phpt @@ -1,5 +1,5 @@ --TEST-- -Ensure exceptions are handled properly when thrown in __call. +Ensure exceptions are handled properly when thrown in __call. --FILE-- <?php class A { diff --git a/tests/classes/__call_007.phpt b/tests/classes/__call_007.phpt index cc7a2773bd..a1dd4594e9 100644 --- a/tests/classes/__call_007.phpt +++ b/tests/classes/__call_007.phpt @@ -1,5 +1,5 @@ --TEST-- -Ensure exceptions are handled properly when thrown in a statically declared __call. +Ensure exceptions are handled properly when thrown in a statically declared __call. --FILE-- <?php class A { diff --git a/tests/classes/__set__get_001.phpt b/tests/classes/__set__get_001.phpt index 3c9cb09b4a..244119a2d0 100644 --- a/tests/classes/__set__get_001.phpt +++ b/tests/classes/__set__get_001.phpt @@ -13,7 +13,7 @@ class setter { $r = $this->x[$nm]; echo "Returning: $r\n"; return $r; - } + } else { echo "Nothing!\n"; } @@ -21,11 +21,11 @@ class setter { function __set($nm, $val) { echo "Setting [$nm] to $val\n"; - + if (isset($this->x[$nm])) { $this->x[$nm] = $val; echo "OK!\n"; - } + } else { echo "Not OK!\n"; } @@ -42,7 +42,7 @@ $foo->a = 100; $foo->a++; $foo->z++; var_dump($foo); - + ?> --EXPECTF-- Setting [a] to 100 diff --git a/tests/classes/__set__get_004.phpt b/tests/classes/__set__get_004.phpt index 86fc094f87..004edc973a 100644 --- a/tests/classes/__set__get_004.phpt +++ b/tests/classes/__set__get_004.phpt @@ -8,7 +8,7 @@ class Test { function __get($name) { if (isset($this->x[$name])) { return $this->x[$name]; - } + } else { return NULL; diff --git a/tests/classes/__set__get_005.phpt b/tests/classes/__set__get_005.phpt index fd23cf6276..68cfb39df3 100644 --- a/tests/classes/__set__get_005.phpt +++ b/tests/classes/__set__get_005.phpt @@ -10,7 +10,7 @@ class Test echo __METHOD__ . "\n"; if (isset($this->x[$name])) { return $this->x[$name]; - } + } else { return NULL; diff --git a/tests/classes/__set_data_corrupt.phpt b/tests/classes/__set_data_corrupt.phpt index 8b51302ab3..4adf569978 100644 --- a/tests/classes/__set_data_corrupt.phpt +++ b/tests/classes/__set_data_corrupt.phpt @@ -6,7 +6,7 @@ $f = 'c="foo"'; class foo { const foobar=1; public $pp = array('t'=>null); - + function bar() { echo $this->t ='f'; } diff --git a/tests/classes/abstract_by_interface_001.phpt b/tests/classes/abstract_by_interface_001.phpt index 7565fdf45f..4a746d0d22 100644 --- a/tests/classes/abstract_by_interface_001.phpt +++ b/tests/classes/abstract_by_interface_001.phpt @@ -16,7 +16,7 @@ abstract class Derived extends Root implements MyInterface { class Leaf extends Derived { - function MyInterfaceFunc() {} + function MyInterfaceFunc() {} } var_dump(new Leaf); diff --git a/tests/classes/abstract_by_interface_002.phpt b/tests/classes/abstract_by_interface_002.phpt index 77c5619dfe..a05660b5b9 100644 --- a/tests/classes/abstract_by_interface_002.phpt +++ b/tests/classes/abstract_by_interface_002.phpt @@ -16,7 +16,7 @@ abstract class Derived extends Root implements MyInterface { class Leaf extends Derived { - static function MyInterfaceFunc() {} + static function MyInterfaceFunc() {} } var_dump(new Leaf); diff --git a/tests/classes/array_access_005.phpt b/tests/classes/array_access_005.phpt index dcb873ff56..92ddeccaf2 100644 --- a/tests/classes/array_access_005.phpt +++ b/tests/classes/array_access_005.phpt @@ -1,11 +1,11 @@ --TEST-- ZE2 ArrayAccess and sub Arrays --FILE-- -<?php +<?php class Peoples implements ArrayAccess { public $person; - + function __construct() { $this->person = array(array('name'=>'Joe')); } diff --git a/tests/classes/array_access_006.phpt b/tests/classes/array_access_006.phpt index 342a7e5107..babc808cb4 100644 --- a/tests/classes/array_access_006.phpt +++ b/tests/classes/array_access_006.phpt @@ -1,11 +1,11 @@ --TEST-- ZE2 ArrayAccess and ASSIGN_OP operators (+=) --FILE-- -<?php +<?php class OverloadedArray implements ArrayAccess { public $realArray; - + function __construct() { $this->realArray = array(1,2,3); } diff --git a/tests/classes/array_access_007.phpt b/tests/classes/array_access_007.phpt index 42187fe5d5..801c8e846c 100644 --- a/tests/classes/array_access_007.phpt +++ b/tests/classes/array_access_007.phpt @@ -1,11 +1,11 @@ --TEST-- ZE2 ArrayAccess and [] assignment --FILE-- -<?php +<?php class OverloadedArray implements ArrayAccess { public $realArray; - + function __construct() { $this->realArray = array(); } diff --git a/tests/classes/array_access_008.phpt b/tests/classes/array_access_008.phpt index 9979889174..0bb793b2b3 100644 --- a/tests/classes/array_access_008.phpt +++ b/tests/classes/array_access_008.phpt @@ -1,11 +1,11 @@ --TEST-- -ZE2 ArrayAccess and ASSIGN_OP operators (.=) +ZE2 ArrayAccess and ASSIGN_OP operators (.=) --FILE-- -<?php +<?php class Peoples implements ArrayAccess { public $person; - + function __construct() { $this->person = array(array('name'=>'Foo')); } diff --git a/tests/classes/array_access_009.phpt b/tests/classes/array_access_009.phpt index 3862240261..7da9084d24 100644 --- a/tests/classes/array_access_009.phpt +++ b/tests/classes/array_access_009.phpt @@ -1,7 +1,7 @@ --TEST-- ZE2 ArrayAccess and ArrayProxyAccess, ArrayProxy --FILE-- -<?php +<?php // NOTE: This will become part of SPL @@ -16,7 +16,7 @@ class ArrayProxy implements ArrayAccess { private $object; private $element; - + function __construct(ArrayProxyAccess $object, $element) { echo __METHOD__ . "($element)\n"; @@ -53,7 +53,7 @@ class ArrayProxy implements ArrayAccess class Peoples implements ArrayProxyAccess { public $person; - + function __construct() { $this->person = array(array('name'=>'Foo')); @@ -88,7 +88,7 @@ class Peoples implements ArrayProxyAccess { $this->person[$element][$index] = $value; } - + function proxyUnset($element, $index) { unset($this->person[$element][$index]); diff --git a/tests/classes/array_access_010.phpt b/tests/classes/array_access_010.phpt index ad374d278c..3df64fcc7e 100644 --- a/tests/classes/array_access_010.phpt +++ b/tests/classes/array_access_010.phpt @@ -1,7 +1,7 @@ --TEST-- ZE2 ArrayAccess and ArrayReferenceProxy with references --FILE-- -<?php +<?php // NOTE: This will become part of SPL @@ -9,7 +9,7 @@ class ArrayReferenceProxy implements ArrayAccess { private $object; private $element; - + function __construct(ArrayAccess $object, array &$element) { echo __METHOD__ . "(Array)\n"; @@ -41,7 +41,7 @@ class ArrayReferenceProxy implements ArrayAccess class Peoples implements ArrayAccess { public $person; - + function __construct() { $this->person = array(array('name'=>'Foo')); diff --git a/tests/classes/array_access_011.phpt b/tests/classes/array_access_011.phpt index aa20a56d39..36269c0b41 100644 --- a/tests/classes/array_access_011.phpt +++ b/tests/classes/array_access_011.phpt @@ -1,7 +1,7 @@ --TEST-- ZE2 ArrayAccess and ArrayAccessReferenceProxy with references to main array --FILE-- -<?php +<?php // NOTE: This will become part of SPL @@ -10,7 +10,7 @@ class ArrayAccessReferenceProxy implements ArrayAccess private $object; private $oarray; private $element; - + function __construct(ArrayAccess $object, array &$array, $element) { echo __METHOD__ . "($element)\n"; @@ -43,7 +43,7 @@ class ArrayAccessReferenceProxy implements ArrayAccess class Peoples implements ArrayAccess { public $person; - + function __construct() { $this->person = array(array('name'=>'Foo')); diff --git a/tests/classes/assign_op_property_001.phpt b/tests/classes/assign_op_property_001.phpt index 21e131cfa4..cd5fcff469 100644 --- a/tests/classes/assign_op_property_001.phpt +++ b/tests/classes/assign_op_property_001.phpt @@ -1,11 +1,11 @@ --TEST-- ZE2 assign_op property of overloaded object --FILE-- -<?php +<?php class Test { private $real_a = 2; - + function __set($property, $value) { if ($property == "a") { $this->real_a = $value; diff --git a/tests/classes/autoload_001.phpt b/tests/classes/autoload_001.phpt index 6c09c4e04d..22bbb6bc7a 100644 --- a/tests/classes/autoload_001.phpt +++ b/tests/classes/autoload_001.phpt @@ -1,7 +1,7 @@ --TEST-- ZE2 Autoload and class_exists --SKIPIF-- -<?php +<?php if (class_exists('autoload_root', false)) die('skip Autoload test classes exist already'); ?> --FILE-- diff --git a/tests/classes/autoload_002.phpt b/tests/classes/autoload_002.phpt index ecb1a44512..3ea84370da 100644 --- a/tests/classes/autoload_002.phpt +++ b/tests/classes/autoload_002.phpt @@ -1,7 +1,7 @@ --TEST-- ZE2 Autoload and get_class_methods --SKIPIF-- -<?php +<?php if (class_exists('autoload_root', false)) die('skip Autoload test classes exist already'); ?> --FILE-- diff --git a/tests/classes/autoload_003.phpt b/tests/classes/autoload_003.phpt index f79b85a9f0..cb82c06e19 100644 --- a/tests/classes/autoload_003.phpt +++ b/tests/classes/autoload_003.phpt @@ -1,7 +1,7 @@ --TEST-- ZE2 Autoload and derived classes --SKIPIF-- -<?php +<?php if (class_exists('autoload_root', false)) die('skip Autoload test classes exist already'); ?> --FILE-- diff --git a/tests/classes/autoload_004.phpt b/tests/classes/autoload_004.phpt index 1f754ca030..f5830ca6cd 100644 --- a/tests/classes/autoload_004.phpt +++ b/tests/classes/autoload_004.phpt @@ -1,7 +1,7 @@ --TEST-- ZE2 Autoload and recursion --SKIPIF-- -<?php +<?php if (class_exists('autoload_root', false)) die('skip Autoload test classes exist already'); ?> --FILE-- diff --git a/tests/classes/autoload_005.phpt b/tests/classes/autoload_005.phpt index 26f4d6ae10..c21a442056 100644 --- a/tests/classes/autoload_005.phpt +++ b/tests/classes/autoload_005.phpt @@ -1,7 +1,7 @@ --TEST-- ZE2 Autoload from destructor --SKIPIF-- -<?php +<?php if (class_exists('autoload_root', false)) die('skip Autoload test classes exist already'); ?> --FILE-- diff --git a/tests/classes/autoload_006.phpt b/tests/classes/autoload_006.phpt index 092e2e2252..69598afc8d 100644 --- a/tests/classes/autoload_006.phpt +++ b/tests/classes/autoload_006.phpt @@ -1,7 +1,7 @@ --TEST-- ZE2 Autoload from destructor --SKIPIF-- -<?php +<?php if (class_exists('autoload_root', false)) die('skip Autoload test classes exist already'); ?> --FILE-- diff --git a/tests/classes/autoload_009.phpt b/tests/classes/autoload_009.phpt index ebe691ca28..63f1ea9801 100644 --- a/tests/classes/autoload_009.phpt +++ b/tests/classes/autoload_009.phpt @@ -1,5 +1,5 @@ --TEST-- -Ensure type hints for unknown types do not trigger autoload. +Ensure type hints for unknown types do not trigger autoload. --FILE-- <?php spl_autoload_register(function ($name) { diff --git a/tests/classes/autoload_018.phpt b/tests/classes/autoload_018.phpt index 53792d6f6b..4a21fad338 100644 --- a/tests/classes/autoload_018.phpt +++ b/tests/classes/autoload_018.phpt @@ -4,15 +4,15 @@ Ensure __autoload() allows for recursive calls if the class name differs. <?php spl_autoload_register(function ($name) { echo "IN: autoload($name)\n"; - + static $i = 0; if ($i++ > 10) { echo "-> Recursion detected - as expected.\n"; return; } - + class_exists('UndefinedClass' . $i); - + echo "OUT: autoload($name)\n"; }); diff --git a/tests/classes/bug23951.phpt b/tests/classes/bug23951.phpt index 2e272b87fe..74b9332d69 100644 --- a/tests/classes/bug23951.phpt +++ b/tests/classes/bug23951.phpt @@ -7,15 +7,15 @@ define('FOO1', 1); define('FOO2', 2); class A { - + public $a_var = array(FOO1=>'foo1_value', FOO2=>'foo2_value'); - + } class B extends A { - - public $b_var = 'foo'; - + + public $b_var = 'foo'; + } $a = new A; diff --git a/tests/classes/bug29446.phpt b/tests/classes/bug29446.phpt index 573f136ce0..9ce2309cba 100644 --- a/tests/classes/bug29446.phpt +++ b/tests/classes/bug29446.phpt @@ -6,7 +6,7 @@ Bug #29446 (ZE allows multiple declarations of the same class constant) class testClass { const TEST_CONST = 'test'; const TEST_CONST = 'test1'; - + function testClass() { echo self::TEST_CONST; } diff --git a/tests/classes/class_example.phpt b/tests/classes/class_example.phpt index 621958b1bd..b0e9cf8f6e 100644 --- a/tests/classes/class_example.phpt +++ b/tests/classes/class_example.phpt @@ -2,7 +2,7 @@ Classes general test --FILE-- -<?php +<?php /* pretty nifty object oriented code! */ diff --git a/tests/classes/constants_basic_001.phpt b/tests/classes/constants_basic_001.phpt index 37120579f6..03af299ba8 100644 --- a/tests/classes/constants_basic_001.phpt +++ b/tests/classes/constants_basic_001.phpt @@ -6,31 +6,31 @@ Class constant declarations $def = 456; define('DEFINED_TO_VAR', $def); define('DEFINED_TO_UNDEF_VAR', $undef); - + class C { const c0 = UNDEFINED; - + const c1 = 1, c2 = 1.5; const c3 = + 1, c4 = + 1.5; const c5 = -1, c6 = -1.5; - + const c7 = __LINE__; const c8 = __FILE__; const c9 = __CLASS__; const c10 = __METHOD__; const c11 = __FUNCTION__; - + const c12 = DEFINED; const c13 = DEFINED_TO_VAR; const c14 = DEFINED_TO_UNDEF_VAR; - + const c15 = "hello1"; const c16 = 'hello2'; const c17 = C::c16; const c18 = self::c17; } - + echo "\nAttempt to access various kinds of class constants:\n"; var_dump(C::c0); var_dump(C::c1); @@ -51,10 +51,10 @@ Class constant declarations var_dump(C::c16); var_dump(C::c17); var_dump(C::c18); - + echo "\nExpecting fatal error:\n"; var_dump(C::c19); - + echo "\nYou should not see this."; ?> --EXPECTF-- diff --git a/tests/classes/constants_basic_002.phpt b/tests/classes/constants_basic_002.phpt index 0e53ca97c8..006e5fbab9 100644 --- a/tests/classes/constants_basic_002.phpt +++ b/tests/classes/constants_basic_002.phpt @@ -6,14 +6,14 @@ Basic class support - defining and reading a class constant. { const myConst = "hello"; } - + echo "\nRead class constant.\n"; var_dump(aclass::myConst); - + echo "\nFail to read class constant from instance.\n"; $myInstance = new aclass(); var_dump($myInstance->myConst); - + echo "\nClass constant not visible in object var_dump.\n"; var_dump($myInstance) ?> diff --git a/tests/classes/constants_basic_003.phpt b/tests/classes/constants_basic_003.phpt index cceabd8d7d..abf48e3c82 100644 --- a/tests/classes/constants_basic_003.phpt +++ b/tests/classes/constants_basic_003.phpt @@ -10,12 +10,12 @@ Ensure class properties and constants can be defined in terms of constants that const ca = A::MY_CONST; const cc = C::MY_CONST; } - + class C { const MY_CONST = "hello from C"; } - + var_dump(B::$a); var_dump(B::$c); var_dump(B::ca); diff --git a/tests/classes/constants_basic_004.phpt b/tests/classes/constants_basic_004.phpt index cade66844b..e893768629 100644 --- a/tests/classes/constants_basic_004.phpt +++ b/tests/classes/constants_basic_004.phpt @@ -1,5 +1,5 @@ --TEST-- -Test properties with array default values using class constants as keys and values. +Test properties with array default values using class constants as keys and values. --FILE-- <?php class X @@ -8,33 +8,33 @@ Test properties with array default values using class constants as keys and valu public static $sa_x = array(B::KEY => B::VALUE); public $a_x = array(B::KEY => B::VALUE); } - + class B { const KEY = "key"; const VALUE = "value"; - + // Static and instance array using class constants with self public static $sa_b = array(self::KEY => self::VALUE); public $a_b = array(self::KEY => self::VALUE); } - + class C extends B { - // Static and instance array using class constants with parent + // Static and instance array using class constants with parent public static $sa_c_parent = array(parent::KEY => parent::VALUE); public $a_c_parent = array(parent::KEY => parent::VALUE); - + // Static and instance array using class constants with self (constants should be inherited) public static $sa_c_self = array(self::KEY => self::VALUE); public $a_c_self = array(self::KEY => self::VALUE); - + // Should also include inherited properties from B. } - + echo "\nStatic properties:\n"; var_dump(X::$sa_x, B::$sa_b, C::$sa_b, C::$sa_c_parent, C::$sa_c_self); - + echo "\nInstance properties:\n"; $x = new x; $b = new B; diff --git a/tests/classes/constants_basic_005.phpt b/tests/classes/constants_basic_005.phpt index a97be1004a..55d23f77b1 100644 --- a/tests/classes/constants_basic_005.phpt +++ b/tests/classes/constants_basic_005.phpt @@ -1,5 +1,5 @@ --TEST-- -Test constants with default values based on other constants. +Test constants with default values based on other constants. --FILE-- <?php class C diff --git a/tests/classes/constants_basic_006.phpt b/tests/classes/constants_basic_006.phpt index 904593ea9b..a293c0bede 100644 --- a/tests/classes/constants_basic_006.phpt +++ b/tests/classes/constants_basic_006.phpt @@ -7,16 +7,16 @@ Ensure class constants are not evaluated when a class is looked up to resolve in const X = E::A; public static $a = array(K => D::V, E::A => K); } - + eval('class D extends C { const V = \'test\'; }'); - + class E extends D { const A = "hello"; } - + define('K', "nasty"); - + var_dump(C::X, C::$a, D::X, D::$a, E::X, E::$a); ?> --EXPECT-- diff --git a/tests/classes/constants_comments_001.phpt b/tests/classes/constants_comments_001.phpt index dbdd67c332..297ad9f956 100644 --- a/tests/classes/constants_comments_001.phpt +++ b/tests/classes/constants_comments_001.phpt @@ -5,17 +5,17 @@ opcache.save_comments=1 --FILE-- <?php class X { - /** comment X1 */ + /** comment X1 */ const X1 = 1; const X2 = 2; - /** comment X3 */ + /** comment X3 */ const X3 = 3; } class Y extends X { - /** comment Y1 */ + /** comment Y1 */ const Y1 = 1; const Y2 = 2; - /** comment Y3 */ + /** comment Y3 */ const Y3 = 3; } $r = new ReflectionClass('Y'); diff --git a/tests/classes/constants_error_003.phpt b/tests/classes/constants_error_003.phpt index c67768c809..b56679b388 100644 --- a/tests/classes/constants_error_003.phpt +++ b/tests/classes/constants_error_003.phpt @@ -6,12 +6,12 @@ Basic class support - attempting to pass a class constant by reference. { const myConst = "hello"; } - + function f(&$a) { $a = "changed"; } - + f(aclass::myConst); var_dump(aclass::myConst); ?> diff --git a/tests/classes/constants_error_004.phpt b/tests/classes/constants_error_004.phpt index 27777f8772..b7f668909b 100644 --- a/tests/classes/constants_error_004.phpt +++ b/tests/classes/constants_error_004.phpt @@ -6,7 +6,7 @@ Class constant whose initial value references a non-existent class { const c1 = D::hello; } - + $a = new C(); ?> --EXPECTF-- diff --git a/tests/classes/constants_error_006.phpt b/tests/classes/constants_error_006.phpt index f3f14b867b..01839ba7ef 100644 --- a/tests/classes/constants_error_006.phpt +++ b/tests/classes/constants_error_006.phpt @@ -6,7 +6,7 @@ Basic class support - attempting to modify a class constant by assignment { const myConst = "hello"; } - + echo "\nTrying to modify a class constant directly - should be parse error.\n"; aclass::myConst = "no!!"; var_dump(aclass::myConst); diff --git a/tests/classes/constants_error_007.phpt b/tests/classes/constants_error_007.phpt index 4be8d885f5..54b32e4ab2 100644 --- a/tests/classes/constants_error_007.phpt +++ b/tests/classes/constants_error_007.phpt @@ -6,7 +6,7 @@ Basic class support - attempting to create a reference to a class constant { const myConst = "hello"; } - + echo "\nAttempting to create a reference to a class constant - should be parse error.\n"; $a = &aclass::myConst; ?> diff --git a/tests/classes/ctor_dtor_inheritance.phpt b/tests/classes/ctor_dtor_inheritance.phpt index 78d4efb32f..5e240571d7 100644 --- a/tests/classes/ctor_dtor_inheritance.phpt +++ b/tests/classes/ctor_dtor_inheritance.phpt @@ -16,7 +16,7 @@ class base { $this->name = 'base'; print_r($this); } - + function __destruct() { echo __CLASS__ . "::" . __FUNCTION__ . "\n"; print_r($this); diff --git a/tests/classes/ctor_failure.phpt b/tests/classes/ctor_failure.phpt index b7d3b64dda..f86b0cc5f8 100644 --- a/tests/classes/ctor_failure.phpt +++ b/tests/classes/ctor_failure.phpt @@ -9,7 +9,7 @@ class Test echo __METHOD__ . "($msg)\n"; throw new Exception($msg); } - + function __destruct() { echo __METHOD__ . "\n"; } diff --git a/tests/classes/ctor_visibility.phpt b/tests/classes/ctor_visibility.phpt index e7288bb968..685c7dbe41 100644 --- a/tests/classes/ctor_visibility.phpt +++ b/tests/classes/ctor_visibility.phpt @@ -18,7 +18,7 @@ class Derived extends Test echo __METHOD__ . "()\n"; parent::__construct(); } - + static function f() { new Derived; @@ -49,7 +49,7 @@ class DerivedPriv extends TestPriv echo __METHOD__ . "()\n"; parent::__construct(); } - + static function f() { new DerivedPriv; diff --git a/tests/classes/destructor_and_echo.phpt b/tests/classes/destructor_and_echo.phpt index 0a253593a5..7d5b57c8ac 100644 --- a/tests/classes/destructor_and_echo.phpt +++ b/tests/classes/destructor_and_echo.phpt @@ -8,7 +8,7 @@ class Test function __construct() { echo __METHOD__ . "\n"; } - + function __destruct() { echo __METHOD__ . "\n"; } diff --git a/tests/classes/destructor_and_globals.phpt b/tests/classes/destructor_and_globals.phpt index 9caf0f1026..1276d28348 100644 --- a/tests/classes/destructor_and_globals.phpt +++ b/tests/classes/destructor_and_globals.phpt @@ -28,7 +28,7 @@ class counter { global $test_cnt; $test_cnt--; } - + static public function destroy(&$obj) { $obj = NULL; } diff --git a/tests/classes/destructor_inheritance.phpt b/tests/classes/destructor_inheritance.phpt index f267a740ae..c527c04b4f 100644 --- a/tests/classes/destructor_inheritance.phpt +++ b/tests/classes/destructor_inheritance.phpt @@ -6,7 +6,7 @@ class base { function __construct() { echo __METHOD__ . "\n"; } - + function __destruct() { echo __METHOD__ . "\n"; } diff --git a/tests/classes/factory_and_singleton_001.phpt b/tests/classes/factory_and_singleton_001.phpt index 970c017f4b..dbbf07cfad 100644 --- a/tests/classes/factory_and_singleton_001.phpt +++ b/tests/classes/factory_and_singleton_001.phpt @@ -41,7 +41,7 @@ class test { return NULL; } } - + static public function count() { return test::$cnt; } diff --git a/tests/classes/factory_and_singleton_002.phpt b/tests/classes/factory_and_singleton_002.phpt index 4812571497..6748321242 100644 --- a/tests/classes/factory_and_singleton_002.phpt +++ b/tests/classes/factory_and_singleton_002.phpt @@ -41,7 +41,7 @@ class test { return NULL; } } - + static public function count() { return test::$cnt; } diff --git a/tests/classes/incdec_property_001.phpt b/tests/classes/incdec_property_001.phpt index 97a24d30b6..8517a9fc4d 100644 --- a/tests/classes/incdec_property_001.phpt +++ b/tests/classes/incdec_property_001.phpt @@ -1,11 +1,11 @@ --TEST-- ZE2 post increment/decrement property of overloaded object --FILE-- -<?php +<?php class Test { private $real_a = 2; - + function __set($property, $value) { if ($property == "a") { $this->real_a = $value; diff --git a/tests/classes/incdec_property_002.phpt b/tests/classes/incdec_property_002.phpt index c1d7dded3b..930a58dc07 100644 --- a/tests/classes/incdec_property_002.phpt +++ b/tests/classes/incdec_property_002.phpt @@ -1,11 +1,11 @@ --TEST-- ZE2 post increment/decrement property of overloaded object with assignment --FILE-- -<?php +<?php class Test { private $real_a = 2; - + function __set($property, $value) { if ($property == "a") { $this->real_a = $value; diff --git a/tests/classes/incdec_property_003.phpt b/tests/classes/incdec_property_003.phpt index 1a923849f4..edf3c00963 100644 --- a/tests/classes/incdec_property_003.phpt +++ b/tests/classes/incdec_property_003.phpt @@ -1,11 +1,11 @@ --TEST-- ZE2 pre increment/decrement property of overloaded object --FILE-- -<?php +<?php class Test { private $real_a = 2; - + function __set($property, $value) { if ($property == "a") { $this->real_a = $value; diff --git a/tests/classes/incdec_property_004.phpt b/tests/classes/incdec_property_004.phpt index 05e3b445ac..2267d568af 100644 --- a/tests/classes/incdec_property_004.phpt +++ b/tests/classes/incdec_property_004.phpt @@ -1,11 +1,11 @@ --TEST-- ZE2 pre increment/decrement property of overloaded object with assignment --FILE-- -<?php +<?php class Test { private $real_a = 2; - + function __set($property, $value) { if ($property == "a") { $this->real_a = $value; diff --git a/tests/classes/inheritance.phpt b/tests/classes/inheritance.phpt index 070ad9147d..3f7e38b9ef 100644 --- a/tests/classes/inheritance.phpt +++ b/tests/classes/inheritance.phpt @@ -1,7 +1,7 @@ --TEST-- Classes inheritance test --FILE-- -<?php +<?php /* Inheritance test. Pretty nifty if I do say so myself! */ diff --git a/tests/classes/inheritance_005.phpt b/tests/classes/inheritance_005.phpt index 7399bf1168..8c5167f4bf 100644 --- a/tests/classes/inheritance_005.phpt +++ b/tests/classes/inheritance_005.phpt @@ -9,25 +9,25 @@ Check for inherited old-style constructor. echo "In " . __METHOD__ . "\n"; } } - + class B extends A { } - + class C extends B { } - - + + echo "About to construct new B: \n"; $b = new B; - + echo "Is B::B() callable?\n"; var_dump(is_callable(array($b, "B"))); - + echo "Is B::A() callable?\n"; var_dump(is_callable(array($b, "A"))); - + echo "About to construct new C: \n"; $c = new C; diff --git a/tests/classes/interface_and_extends.phpt b/tests/classes/interface_and_extends.phpt index 1c23d31ca6..8bb1ec05f1 100644 --- a/tests/classes/interface_and_extends.phpt +++ b/tests/classes/interface_and_extends.phpt @@ -1,5 +1,5 @@ --TEST-- -ZE2 a class cannot extend an interface +ZE2 a class cannot extend an interface --FILE-- <?php diff --git a/tests/classes/interface_class.phpt b/tests/classes/interface_class.phpt index 46deb490ed..8975994024 100644 --- a/tests/classes/interface_class.phpt +++ b/tests/classes/interface_class.phpt @@ -4,7 +4,7 @@ ZE2 A class can only implement interfaces <?php class base { } - + class derived implements base { } ?> diff --git a/tests/classes/interface_constant_inheritance_001.phpt b/tests/classes/interface_constant_inheritance_001.phpt index f982a4a64e..046f3b1c5a 100644 --- a/tests/classes/interface_constant_inheritance_001.phpt +++ b/tests/classes/interface_constant_inheritance_001.phpt @@ -1,5 +1,5 @@ --TEST-- -Ensure an interface may not shadow an inherited constant. +Ensure an interface may not shadow an inherited constant. --FILE-- <?php interface I1 { diff --git a/tests/classes/interface_constant_inheritance_002.phpt b/tests/classes/interface_constant_inheritance_002.phpt index af4ce695f7..952dbaf7f4 100644 --- a/tests/classes/interface_constant_inheritance_002.phpt +++ b/tests/classes/interface_constant_inheritance_002.phpt @@ -1,5 +1,5 @@ --TEST-- -Ensure a class may not shadow a constant inherited from an interface. +Ensure a class may not shadow a constant inherited from an interface. --FILE-- <?php interface I { diff --git a/tests/classes/interface_constant_inheritance_003.phpt b/tests/classes/interface_constant_inheritance_003.phpt index 6b4139bd98..908ca7b4d6 100644 --- a/tests/classes/interface_constant_inheritance_003.phpt +++ b/tests/classes/interface_constant_inheritance_003.phpt @@ -1,5 +1,5 @@ --TEST-- -Ensure a class may not inherit two constants with the same name from two separate interfaces. +Ensure a class may not inherit two constants with the same name from two separate interfaces. --FILE-- <?php interface I1 { diff --git a/tests/classes/interface_constant_inheritance_004.phpt b/tests/classes/interface_constant_inheritance_004.phpt index 7f2d3e514f..aca9865eb1 100644 --- a/tests/classes/interface_constant_inheritance_004.phpt +++ b/tests/classes/interface_constant_inheritance_004.phpt @@ -1,5 +1,5 @@ --TEST-- -Ensure a class may implement two interfaces which include the same constant (due to inheritance). +Ensure a class may implement two interfaces which include the same constant (due to inheritance). --FILE-- <?php interface IA { diff --git a/tests/classes/interface_doubled.phpt b/tests/classes/interface_doubled.phpt index e36a3c4553..8fbfcba7ff 100644 --- a/tests/classes/interface_doubled.phpt +++ b/tests/classes/interface_doubled.phpt @@ -6,7 +6,7 @@ ZE2 An interface extends base interfaces interface if_a { function f_a(); } - + interface if_b { function f_b(); } diff --git a/tests/classes/interface_implemented.phpt b/tests/classes/interface_implemented.phpt index fd303e0913..e224c5bd23 100644 --- a/tests/classes/interface_implemented.phpt +++ b/tests/classes/interface_implemented.phpt @@ -6,7 +6,7 @@ ZE2 An interface is inherited interface if_a { function f_a(); } - + interface if_b extends if_a { function f_b(); } diff --git a/tests/classes/interface_instantiate.phpt b/tests/classes/interface_instantiate.phpt index dffd6b10e2..04b0e29701 100644 --- a/tests/classes/interface_instantiate.phpt +++ b/tests/classes/interface_instantiate.phpt @@ -6,7 +6,7 @@ ZE2 An interface cannot be instantiated interface if_a { function f_a(); } - + $t = new if_a(); ?> diff --git a/tests/classes/interface_must_be_implemented.phpt b/tests/classes/interface_must_be_implemented.phpt index cd7c815f50..7dc39436e9 100644 --- a/tests/classes/interface_must_be_implemented.phpt +++ b/tests/classes/interface_must_be_implemented.phpt @@ -6,7 +6,7 @@ ZE2 An interface must be implemented interface if_a { function f_a(); } - + class derived_a implements if_a { } diff --git a/tests/classes/interface_optional_arg_003.phpt b/tests/classes/interface_optional_arg_003.phpt index 8685e3d0f1..cf583fe204 100644 --- a/tests/classes/interface_optional_arg_003.phpt +++ b/tests/classes/interface_optional_arg_003.phpt @@ -1,7 +1,7 @@ --TEST-- default argument value in and in implementing class with interface in included file --FILE-- -<?php +<?php include 'interface_optional_arg_003.inc'; class C implements I { diff --git a/tests/classes/iterators_001.phpt b/tests/classes/iterators_001.phpt index 548bed53ce..e4060e375f 100644 --- a/tests/classes/iterators_001.phpt +++ b/tests/classes/iterators_001.phpt @@ -37,7 +37,7 @@ class c_iter implements Iterator { } } } - + class c implements IteratorAggregate { public $max = 3; diff --git a/tests/classes/iterators_002.phpt b/tests/classes/iterators_002.phpt index 6f93d1e1f9..5e1ceb6208 100644 --- a/tests/classes/iterators_002.phpt +++ b/tests/classes/iterators_002.phpt @@ -41,7 +41,7 @@ class c_iter implements Iterator { echo __METHOD__ . "\n"; } } - + class c implements IteratorAggregate { public $max = 3; diff --git a/tests/classes/iterators_003.phpt b/tests/classes/iterators_003.phpt index 71009e0269..f417478d49 100644 --- a/tests/classes/iterators_003.phpt +++ b/tests/classes/iterators_003.phpt @@ -31,7 +31,7 @@ class c_iter implements Iterator { return $this->num; } } - + class c implements IteratorAggregate { public $max = 4; diff --git a/tests/classes/iterators_006.phpt b/tests/classes/iterators_006.phpt index 564f15de54..7baa077f2b 100644 --- a/tests/classes/iterators_006.phpt +++ b/tests/classes/iterators_006.phpt @@ -45,7 +45,7 @@ class a implements IteratorAggregate { $array = new a(); foreach ($array as $property => $value) { - print "$property: $value\n"; + print "$property: $value\n"; } #$array = $array->getIterator(); @@ -58,13 +58,13 @@ echo "===2nd===\n"; $array = new ai(); foreach ($array as $property => $value) { - print "$property: $value\n"; + print "$property: $value\n"; } echo "===3rd===\n"; foreach ($array as $property => $value) { - print "$property: $value\n"; + print "$property: $value\n"; } ?> diff --git a/tests/classes/iterators_007.phpt b/tests/classes/iterators_007.phpt index f2638b31dc..87b7e5318b 100644 --- a/tests/classes/iterators_007.phpt +++ b/tests/classes/iterators_007.phpt @@ -6,7 +6,7 @@ class Test implements Iterator { public $arr = array(1, 2, 3); public $x = 0; - + public function rewind() { if ($this->x == 0) throw new Exception(__METHOD__); reset($this->arr); } public function current() { if ($this->x == 1) throw new Exception(__METHOD__); return current($this->arr); } public function key() { if ($this->x == 2) throw new Exception(__METHOD__); return key($this->arr); } diff --git a/tests/classes/iterators_008.phpt b/tests/classes/iterators_008.phpt index 13a8b165cd..26c8e01704 100644 --- a/tests/classes/iterators_008.phpt +++ b/tests/classes/iterators_008.phpt @@ -5,31 +5,31 @@ Ensure plain userspace superclass does not override special iterator behaviour o Class C {} class D extends C implements Iterator { - + private $counter = 2; - + public function valid() { echo __METHOD__ . "($this->counter)\n"; - return $this->counter; + return $this->counter; } - + public function next() { - $this->counter--; + $this->counter--; echo __METHOD__ . "($this->counter)\n"; } - + public function rewind() { echo __METHOD__ . "($this->counter)\n"; } - + public function current() { echo __METHOD__ . "($this->counter)\n"; } - + public function key() { echo __METHOD__ . "($this->counter)\n"; } - + } foreach (new D as $x) {} diff --git a/tests/classes/method_call_variation_001.phpt b/tests/classes/method_call_variation_001.phpt index e4e269f070..5b6b725bc2 100644 --- a/tests/classes/method_call_variation_001.phpt +++ b/tests/classes/method_call_variation_001.phpt @@ -13,10 +13,10 @@ In $a->$b[Y]() and $a->X[Y]() both $a->$b[Y] and $a->X[Y] represent a global fun $c = new C; $c->functions[0] = 'foo'; $c->functions[1][2][3][4] = 'foo'; - + $c->$name[0](1, 2); $c->$name[1][2][3][4](3, 4); - + $c->functions[0](5, 6); $c->functions[1][2][3][4](7, 8); ?> diff --git a/tests/classes/method_override_optional_arg_002.phpt b/tests/classes/method_override_optional_arg_002.phpt index c62e3a562e..254392718b 100644 --- a/tests/classes/method_override_optional_arg_002.phpt +++ b/tests/classes/method_override_optional_arg_002.phpt @@ -1,5 +1,5 @@ --TEST-- -Omitting optional arg in method inherited from abstract class +Omitting optional arg in method inherited from abstract class --FILE-- <?php diff --git a/tests/classes/object_reference_001.phpt b/tests/classes/object_reference_001.phpt index ca5bbc5abe..9842ac00f5 100644 --- a/tests/classes/object_reference_001.phpt +++ b/tests/classes/object_reference_001.phpt @@ -5,7 +5,7 @@ ZE2 object references class Foo { public $name; - + function __construct() { $this->name = "I'm Foo!\n"; } diff --git a/tests/classes/private_006.phpt b/tests/classes/private_006.phpt index 9b90c9c1a7..895affac75 100644 --- a/tests/classes/private_006.phpt +++ b/tests/classes/private_006.phpt @@ -14,7 +14,7 @@ class first { first::do_show(); -class second extends first { +class second extends first { } second::do_show(); diff --git a/tests/classes/private_006b.phpt b/tests/classes/private_006b.phpt index 272a334bfa..1c678601b6 100644 --- a/tests/classes/private_006b.phpt +++ b/tests/classes/private_006b.phpt @@ -16,7 +16,7 @@ class first { $t1 = new first(); $t1->do_show(); -class second extends first { +class second extends first { } //$t2 = new second(); diff --git a/tests/classes/private_007.phpt b/tests/classes/private_007.phpt index 53bc7be059..abc2258bc2 100644 --- a/tests/classes/private_007.phpt +++ b/tests/classes/private_007.phpt @@ -12,7 +12,7 @@ class Bar { } } class Foo extends Bar { - public static function priv() { + public static function priv() { echo "Foo::priv()\n"; } } diff --git a/tests/classes/private_007b.phpt b/tests/classes/private_007b.phpt index 62a65f4cee..3272d0c8a0 100644 --- a/tests/classes/private_007b.phpt +++ b/tests/classes/private_007b.phpt @@ -12,7 +12,7 @@ class Bar { } } class Foo extends Bar { - public function priv() { + public function priv() { echo "Foo::priv()\n"; } } diff --git a/tests/classes/private_members.phpt b/tests/classes/private_members.phpt index 5ab448e437..4d8fd9eeb0 100644 --- a/tests/classes/private_members.phpt +++ b/tests/classes/private_members.phpt @@ -1,5 +1,5 @@ --TEST-- -ZE2 A private member is +ZE2 A private member is --FILE-- <?php diff --git a/tests/classes/property_override_privateStatic_private.phpt b/tests/classes/property_override_privateStatic_private.phpt index b2985add7d..5be1eaf509 100644 --- a/tests/classes/property_override_privateStatic_private.phpt +++ b/tests/classes/property_override_privateStatic_private.phpt @@ -10,7 +10,7 @@ Redeclare inherited private static property as private. echo self::$p . "\n"; } } - + class B extends A { private $p = "B::p"; @@ -19,10 +19,10 @@ Redeclare inherited private static property as private. echo $this->p . "\n"; } } - - + + A::showA(); - + $b = new B; $b->showA(); $b->showB(); diff --git a/tests/classes/property_override_privateStatic_privateStatic.phpt b/tests/classes/property_override_privateStatic_privateStatic.phpt index f435516a3f..2a1488a319 100644 --- a/tests/classes/property_override_privateStatic_privateStatic.phpt +++ b/tests/classes/property_override_privateStatic_privateStatic.phpt @@ -10,7 +10,7 @@ Redeclare inherited private static property as private static. echo self::$p . "\n"; } } - + class B extends A { private static $p = "B::p (static)"; @@ -19,10 +19,10 @@ Redeclare inherited private static property as private static. echo self::$p . "\n"; } } - - + + A::showA(); - + B::showA(); B::showB(); ?> diff --git a/tests/classes/property_override_privateStatic_protected.phpt b/tests/classes/property_override_privateStatic_protected.phpt index fac66c32bb..8e570ddbad 100644 --- a/tests/classes/property_override_privateStatic_protected.phpt +++ b/tests/classes/property_override_privateStatic_protected.phpt @@ -10,7 +10,7 @@ Redeclare inherited private static property as protected. echo self::$p . "\n"; } } - + class B extends A { protected $p = "B::p"; @@ -19,10 +19,10 @@ Redeclare inherited private static property as protected. echo $this->p . "\n"; } } - - + + A::showA(); - + $b = new B; $b->showA(); $b->showB(); diff --git a/tests/classes/property_override_privateStatic_protectedStatic.phpt b/tests/classes/property_override_privateStatic_protectedStatic.phpt index 08c0b22704..03e1abddf2 100644 --- a/tests/classes/property_override_privateStatic_protectedStatic.phpt +++ b/tests/classes/property_override_privateStatic_protectedStatic.phpt @@ -10,7 +10,7 @@ Redeclare inherited private static property as protected static. echo self::$p . "\n"; } } - + class B extends A { protected static $p = "B::p (static)"; @@ -19,10 +19,10 @@ Redeclare inherited private static property as protected static. echo self::$p . "\n"; } } - - + + A::showA(); - + B::showA(); B::showB(); ?> diff --git a/tests/classes/property_override_privateStatic_public.phpt b/tests/classes/property_override_privateStatic_public.phpt index 7242371003..1db49f9845 100644 --- a/tests/classes/property_override_privateStatic_public.phpt +++ b/tests/classes/property_override_privateStatic_public.phpt @@ -10,7 +10,7 @@ Redeclare inherited private static property as public. echo self::$p . "\n"; } } - + class B extends A { public $p = "B::p"; @@ -19,10 +19,10 @@ Redeclare inherited private static property as public. echo $this->p . "\n"; } } - - + + A::showA(); - + $b = new B; $b->showA(); $b->showB(); diff --git a/tests/classes/property_override_privateStatic_publicStatic.phpt b/tests/classes/property_override_privateStatic_publicStatic.phpt index 1fe43fb619..2a18747a30 100644 --- a/tests/classes/property_override_privateStatic_publicStatic.phpt +++ b/tests/classes/property_override_privateStatic_publicStatic.phpt @@ -10,7 +10,7 @@ Redeclare inherited private static property as public static. echo self::$p . "\n"; } } - + class B extends A { public static $p = "B::p (static)"; @@ -19,10 +19,10 @@ Redeclare inherited private static property as public static. echo self::$p . "\n"; } } - - + + A::showA(); - + B::showA(); B::showB(); ?> diff --git a/tests/classes/property_override_private_private.phpt b/tests/classes/property_override_private_private.phpt index 2d45f33430..74184d111a 100644 --- a/tests/classes/property_override_private_private.phpt +++ b/tests/classes/property_override_private_private.phpt @@ -10,7 +10,7 @@ Redeclare inherited private property as private. echo $this->p . "\n"; } } - + class B extends A { private $p = "B::p"; @@ -19,11 +19,11 @@ Redeclare inherited private property as private. echo $this->p . "\n"; } } - - + + $a = new A; $a->showA(); - + $b = new B; $b->showA(); $b->showB(); diff --git a/tests/classes/property_override_private_privateStatic.phpt b/tests/classes/property_override_private_privateStatic.phpt index 1bc3c9fe52..3aead95c0c 100644 --- a/tests/classes/property_override_private_privateStatic.phpt +++ b/tests/classes/property_override_private_privateStatic.phpt @@ -10,7 +10,7 @@ Redeclare inherited private property as private static. echo $this->p . "\n"; } } - + class B extends A { private static $p = "B::p (static)"; @@ -19,11 +19,11 @@ Redeclare inherited private property as private static. echo self::$p . "\n"; } } - - + + $a = new A; $a->showA(); - + $b = new B; $b->showA(); B::showB(); diff --git a/tests/classes/property_override_private_protected.phpt b/tests/classes/property_override_private_protected.phpt index d284272d02..25f6e5218f 100644 --- a/tests/classes/property_override_private_protected.phpt +++ b/tests/classes/property_override_private_protected.phpt @@ -10,7 +10,7 @@ Redeclare inherited private property as protected. echo $this->p . "\n"; } } - + class B extends A { protected $p = "B::p"; @@ -19,11 +19,11 @@ Redeclare inherited private property as protected. echo $this->p . "\n"; } } - - + + $a = new A; $a->showA(); - + $b = new B; $b->showA(); $b->showB(); diff --git a/tests/classes/property_override_private_protectedStatic.phpt b/tests/classes/property_override_private_protectedStatic.phpt index c7c54eab95..6ccc953503 100644 --- a/tests/classes/property_override_private_protectedStatic.phpt +++ b/tests/classes/property_override_private_protectedStatic.phpt @@ -10,7 +10,7 @@ Redeclare inherited private property as protected static. echo $this->p . "\n"; } } - + class B extends A { protected static $p = "B::p (static)"; @@ -19,11 +19,11 @@ Redeclare inherited private property as protected static. echo self::$p . "\n"; } } - - + + $a = new A; $a->showA(); - + $b = new B; $b->showA(); B::showB(); diff --git a/tests/classes/property_override_private_public.phpt b/tests/classes/property_override_private_public.phpt index 6468432d18..e54d1370de 100644 --- a/tests/classes/property_override_private_public.phpt +++ b/tests/classes/property_override_private_public.phpt @@ -10,7 +10,7 @@ Redeclare inherited private property as public. echo $this->p . "\n"; } } - + class B extends A { public $p = "B::p"; @@ -19,11 +19,11 @@ Redeclare inherited private property as public. echo $this->p . "\n"; } } - - + + $a = new A; $a->showA(); - + $b = new B; $b->showA(); $b->showB(); diff --git a/tests/classes/property_override_private_publicStatic.phpt b/tests/classes/property_override_private_publicStatic.phpt index 4057f83390..67c44a3f30 100644 --- a/tests/classes/property_override_private_publicStatic.phpt +++ b/tests/classes/property_override_private_publicStatic.phpt @@ -10,7 +10,7 @@ Redeclare inherited private property as public static. echo $this->p . "\n"; } } - + class B extends A { public static $p = "B::p (static)"; @@ -19,11 +19,11 @@ Redeclare inherited private property as public static. echo self::$p . "\n"; } } - - + + $a = new A; $a->showA(); - + $b = new B; $b->showA(); B::showB(); diff --git a/tests/classes/property_override_protectedStatic_private.phpt b/tests/classes/property_override_protectedStatic_private.phpt index 18e9c78a13..712f51cd3c 100644 --- a/tests/classes/property_override_protectedStatic_private.phpt +++ b/tests/classes/property_override_protectedStatic_private.phpt @@ -10,7 +10,7 @@ Redeclare inherited protected static property as private. echo self::$p . "\n"; } } - + class B extends A { private $p = "B::p"; @@ -19,10 +19,10 @@ Redeclare inherited protected static property as private. echo $this->p . "\n"; } } - - + + A::showA(); - + $b = new B; $b->showA(); $b->showB(); diff --git a/tests/classes/property_override_protectedStatic_privateStatic.phpt b/tests/classes/property_override_protectedStatic_privateStatic.phpt index 688621077d..72e6e8a0a2 100644 --- a/tests/classes/property_override_protectedStatic_privateStatic.phpt +++ b/tests/classes/property_override_protectedStatic_privateStatic.phpt @@ -10,7 +10,7 @@ Redeclare inherited protected static property as private static. echo self::$p . "\n"; } } - + class B extends A { private static $p = "B::p (static)"; @@ -19,10 +19,10 @@ Redeclare inherited protected static property as private static. echo self::$p . "\n"; } } - - + + A::showA(); - + B::showA(); B::showB(); ?> diff --git a/tests/classes/property_override_protectedStatic_protected.phpt b/tests/classes/property_override_protectedStatic_protected.phpt index 0e5fdd301c..b6780586c4 100644 --- a/tests/classes/property_override_protectedStatic_protected.phpt +++ b/tests/classes/property_override_protectedStatic_protected.phpt @@ -10,7 +10,7 @@ Redeclare inherited protected static property as protected. echo self::$p . "\n"; } } - + class B extends A { protected $p = "B::p"; @@ -19,10 +19,10 @@ Redeclare inherited protected static property as protected. echo $this->p . "\n"; } } - - + + A::showA(); - + $b = new B; $b->showA(); $b->showB(); diff --git a/tests/classes/property_override_protectedStatic_protectedStatic.phpt b/tests/classes/property_override_protectedStatic_protectedStatic.phpt index d2d1c0c379..c81a60423e 100644 --- a/tests/classes/property_override_protectedStatic_protectedStatic.phpt +++ b/tests/classes/property_override_protectedStatic_protectedStatic.phpt @@ -10,7 +10,7 @@ Redeclare inherited protected static property as protected static. echo self::$p . "\n"; } } - + class B extends A { protected static $p = "B::p (static)"; @@ -19,10 +19,10 @@ Redeclare inherited protected static property as protected static. echo self::$p . "\n"; } } - - + + A::showA(); - + B::showA(); B::showB(); ?> diff --git a/tests/classes/property_override_protectedStatic_public.phpt b/tests/classes/property_override_protectedStatic_public.phpt index 6303325590..14daa455a6 100644 --- a/tests/classes/property_override_protectedStatic_public.phpt +++ b/tests/classes/property_override_protectedStatic_public.phpt @@ -10,7 +10,7 @@ Redeclare inherited protected static property as public. echo self::$p . "\n"; } } - + class B extends A { public $p = "B::p"; @@ -19,10 +19,10 @@ Redeclare inherited protected static property as public. echo $this->p . "\n"; } } - - + + A::showA(); - + $b = new B; $b->showA(); $b->showB(); diff --git a/tests/classes/property_override_protectedStatic_publicStatic.phpt b/tests/classes/property_override_protectedStatic_publicStatic.phpt index 29b67655ff..a214af9994 100644 --- a/tests/classes/property_override_protectedStatic_publicStatic.phpt +++ b/tests/classes/property_override_protectedStatic_publicStatic.phpt @@ -10,7 +10,7 @@ Redeclare inherited protected static property as public static. echo self::$p . "\n"; } } - + class B extends A { public static $p = "B::p (static)"; @@ -19,10 +19,10 @@ Redeclare inherited protected static property as public static. echo self::$p . "\n"; } } - - + + A::showA(); - + B::showA(); B::showB(); ?> diff --git a/tests/classes/property_override_protected_private.phpt b/tests/classes/property_override_protected_private.phpt index 22cceda175..9875dd59b8 100644 --- a/tests/classes/property_override_protected_private.phpt +++ b/tests/classes/property_override_protected_private.phpt @@ -10,7 +10,7 @@ Redeclare inherited protected property as private (duplicates Zend/tests/errmsg_ echo $this->p . "\n"; } } - + class B extends A { private $p = "B::p"; @@ -19,11 +19,11 @@ Redeclare inherited protected property as private (duplicates Zend/tests/errmsg_ echo $this->p . "\n"; } } - - + + $a = new A; $a->showA(); - + $b = new B; $b->showA(); $b->showB(); diff --git a/tests/classes/property_override_protected_privateStatic.phpt b/tests/classes/property_override_protected_privateStatic.phpt index fb7102cb3e..7193178d48 100644 --- a/tests/classes/property_override_protected_privateStatic.phpt +++ b/tests/classes/property_override_protected_privateStatic.phpt @@ -10,7 +10,7 @@ Redeclare inherited protected property as private static. echo $this->p . "\n"; } } - + class B extends A { private static $p = "B::p (static)"; @@ -19,11 +19,11 @@ Redeclare inherited protected property as private static. echo self::$p . "\n"; } } - - + + $a = new A; $a->showA(); - + $b = new B; $b->showA(); B::showB(); diff --git a/tests/classes/property_override_protected_protected.phpt b/tests/classes/property_override_protected_protected.phpt index 096f53d515..c302639fbb 100644 --- a/tests/classes/property_override_protected_protected.phpt +++ b/tests/classes/property_override_protected_protected.phpt @@ -10,7 +10,7 @@ Redeclare inherited protected property as protected. echo $this->p . "\n"; } } - + class B extends A { protected $p = "B::p"; @@ -19,11 +19,11 @@ Redeclare inherited protected property as protected. echo $this->p . "\n"; } } - - + + $a = new A; $a->showA(); - + $b = new B; $b->showA(); $b->showB(); diff --git a/tests/classes/property_override_protected_protectedStatic.phpt b/tests/classes/property_override_protected_protectedStatic.phpt index 1ce4130265..abac19a793 100644 --- a/tests/classes/property_override_protected_protectedStatic.phpt +++ b/tests/classes/property_override_protected_protectedStatic.phpt @@ -10,7 +10,7 @@ Redeclare inherited protected property as protected static. echo $this->p . "\n"; } } - + class B extends A { protected static $p = "B::p (static)"; @@ -19,11 +19,11 @@ Redeclare inherited protected property as protected static. echo self::$p . "\n"; } } - - + + $a = new A; $a->showA(); - + $b = new B; $b->showA(); B::showB(); diff --git a/tests/classes/property_override_protected_public.phpt b/tests/classes/property_override_protected_public.phpt index c2db91b14c..378003ba54 100644 --- a/tests/classes/property_override_protected_public.phpt +++ b/tests/classes/property_override_protected_public.phpt @@ -10,7 +10,7 @@ Redeclare inherited protected property as public. echo $this->p . "\n"; } } - + class B extends A { public $p = "B::p"; @@ -19,11 +19,11 @@ Redeclare inherited protected property as public. echo $this->p . "\n"; } } - - + + $a = new A; $a->showA(); - + $b = new B; $b->showA(); $b->showB(); diff --git a/tests/classes/property_override_protected_publicStatic.phpt b/tests/classes/property_override_protected_publicStatic.phpt index 8efdf5f6fd..37865cc7d4 100644 --- a/tests/classes/property_override_protected_publicStatic.phpt +++ b/tests/classes/property_override_protected_publicStatic.phpt @@ -10,7 +10,7 @@ Redeclare inherited protected property as public static. echo $this->p . "\n"; } } - + class B extends A { public static $p = "B::p (static)"; @@ -19,11 +19,11 @@ Redeclare inherited protected property as public static. echo self::$p . "\n"; } } - - + + $a = new A; $a->showA(); - + $b = new B; $b->showA(); B::showB(); diff --git a/tests/classes/property_override_publicStatic_private.phpt b/tests/classes/property_override_publicStatic_private.phpt index 7abe92c9ff..6fd2774c54 100644 --- a/tests/classes/property_override_publicStatic_private.phpt +++ b/tests/classes/property_override_publicStatic_private.phpt @@ -10,7 +10,7 @@ Redeclare inherited public static property as private. echo self::$p . "\n"; } } - + class B extends A { private $p = "B::p"; @@ -19,10 +19,10 @@ Redeclare inherited public static property as private. echo $this->p . "\n"; } } - - + + A::showA(); - + $b = new B; $b->showA(); $b->showB(); diff --git a/tests/classes/property_override_publicStatic_privateStatic.phpt b/tests/classes/property_override_publicStatic_privateStatic.phpt index d41db6da38..3635b918db 100644 --- a/tests/classes/property_override_publicStatic_privateStatic.phpt +++ b/tests/classes/property_override_publicStatic_privateStatic.phpt @@ -10,7 +10,7 @@ Redeclare inherited public static property as private static. echo self::$p . "\n"; } } - + class B extends A { private static $p = "B::p (static)"; @@ -19,10 +19,10 @@ Redeclare inherited public static property as private static. echo self::$p . "\n"; } } - - + + A::showA(); - + B::showA(); B::showB(); ?> diff --git a/tests/classes/property_override_publicStatic_protected.phpt b/tests/classes/property_override_publicStatic_protected.phpt index 884159f977..a5eaaea714 100644 --- a/tests/classes/property_override_publicStatic_protected.phpt +++ b/tests/classes/property_override_publicStatic_protected.phpt @@ -10,7 +10,7 @@ Redeclare inherited public static property as protected. echo self::$p . "\n"; } } - + class B extends A { protected $p = "B::p"; @@ -19,10 +19,10 @@ Redeclare inherited public static property as protected. echo $this->p . "\n"; } } - - + + A::showA(); - + $b = new B; $b->showA(); $b->showB(); diff --git a/tests/classes/property_override_publicStatic_protectedStatic.phpt b/tests/classes/property_override_publicStatic_protectedStatic.phpt index b022ef8049..00eb647d5d 100644 --- a/tests/classes/property_override_publicStatic_protectedStatic.phpt +++ b/tests/classes/property_override_publicStatic_protectedStatic.phpt @@ -10,7 +10,7 @@ Redeclare inherited public static property as protected static. echo self::$p . "\n"; } } - + class B extends A { protected static $p = "B::p (static)"; @@ -19,10 +19,10 @@ Redeclare inherited public static property as protected static. echo self::$p . "\n"; } } - - + + A::showA(); - + B::showA(); B::showB(); ?> diff --git a/tests/classes/property_override_publicStatic_public.phpt b/tests/classes/property_override_publicStatic_public.phpt index d099da0474..f6ea7643c1 100644 --- a/tests/classes/property_override_publicStatic_public.phpt +++ b/tests/classes/property_override_publicStatic_public.phpt @@ -10,7 +10,7 @@ Redeclare inherited public static property as public. echo self::$p . "\n"; } } - + class B extends A { public $p = "B::p"; @@ -19,10 +19,10 @@ Redeclare inherited public static property as public. echo $this->p . "\n"; } } - - + + A::showA(); - + $b = new B; $b->showA(); $b->showB(); diff --git a/tests/classes/property_override_publicStatic_publicStatic.phpt b/tests/classes/property_override_publicStatic_publicStatic.phpt index 8d0f9ad079..708d7fb479 100644 --- a/tests/classes/property_override_publicStatic_publicStatic.phpt +++ b/tests/classes/property_override_publicStatic_publicStatic.phpt @@ -10,7 +10,7 @@ Redeclare inherited public static property as public static. echo self::$p . "\n"; } } - + class B extends A { public static $p = "B::p (static)"; @@ -19,10 +19,10 @@ Redeclare inherited public static property as public static. echo self::$p . "\n"; } } - - + + A::showA(); - + B::showA(); B::showB(); ?> diff --git a/tests/classes/property_override_public_private.phpt b/tests/classes/property_override_public_private.phpt index c0f37ad95a..581d663b60 100644 --- a/tests/classes/property_override_public_private.phpt +++ b/tests/classes/property_override_public_private.phpt @@ -10,7 +10,7 @@ Redeclare inherited public property as private. echo $this->p . "\n"; } } - + class B extends A { private $p = "B::p"; @@ -19,11 +19,11 @@ Redeclare inherited public property as private. echo $this->p . "\n"; } } - - + + $a = new A; $a->showA(); - + $b = new B; $b->showA(); $b->showB(); diff --git a/tests/classes/property_override_public_privateStatic.phpt b/tests/classes/property_override_public_privateStatic.phpt index 36223fd345..bacdc9ffe1 100644 --- a/tests/classes/property_override_public_privateStatic.phpt +++ b/tests/classes/property_override_public_privateStatic.phpt @@ -10,7 +10,7 @@ Redeclare inherited public property as private static. echo $this->p . "\n"; } } - + class B extends A { private static $p = "B::p (static)"; @@ -19,11 +19,11 @@ Redeclare inherited public property as private static. echo self::$p . "\n"; } } - - + + $a = new A; $a->showA(); - + $b = new B; $b->showA(); B::showB(); diff --git a/tests/classes/property_override_public_protected.phpt b/tests/classes/property_override_public_protected.phpt index 68fdf8286f..aa79a53595 100644 --- a/tests/classes/property_override_public_protected.phpt +++ b/tests/classes/property_override_public_protected.phpt @@ -10,7 +10,7 @@ Redeclare inherited public property as protected. echo $this->p . "\n"; } } - + class B extends A { protected $p = "B::p"; @@ -19,11 +19,11 @@ Redeclare inherited public property as protected. echo $this->p . "\n"; } } - - + + $a = new A; $a->showA(); - + $b = new B; $b->showA(); $b->showB(); diff --git a/tests/classes/property_override_public_protectedStatic.phpt b/tests/classes/property_override_public_protectedStatic.phpt index 77e7ebf1f8..8d78713add 100644 --- a/tests/classes/property_override_public_protectedStatic.phpt +++ b/tests/classes/property_override_public_protectedStatic.phpt @@ -10,7 +10,7 @@ Redeclare inherited public property as protected static. echo $this->p . "\n"; } } - + class B extends A { protected static $p = "B::p (static)"; @@ -19,11 +19,11 @@ Redeclare inherited public property as protected static. echo self::$p . "\n"; } } - - + + $a = new A; $a->showA(); - + $b = new B; $b->showA(); B::showB(); diff --git a/tests/classes/property_override_public_public.phpt b/tests/classes/property_override_public_public.phpt index 3abfe24e29..83d3929702 100644 --- a/tests/classes/property_override_public_public.phpt +++ b/tests/classes/property_override_public_public.phpt @@ -10,7 +10,7 @@ Redeclare inherited public property as public. echo $this->p . "\n"; } } - + class B extends A { public $p = "B::p"; @@ -19,11 +19,11 @@ Redeclare inherited public property as public. echo $this->p . "\n"; } } - - + + $a = new A; $a->showA(); - + $b = new B; $b->showA(); $b->showB(); diff --git a/tests/classes/property_override_public_publicStatic.phpt b/tests/classes/property_override_public_publicStatic.phpt index 725e947a0d..94feea8a22 100644 --- a/tests/classes/property_override_public_publicStatic.phpt +++ b/tests/classes/property_override_public_publicStatic.phpt @@ -10,7 +10,7 @@ Redeclare inherited public property as public static. echo $this->p . "\n"; } } - + class B extends A { public static $p = "B::p (static)"; @@ -19,11 +19,11 @@ Redeclare inherited public property as public static. echo self::$p . "\n"; } } - - + + $a = new A; $a->showA(); - + $b = new B; $b->showA(); B::showB(); diff --git a/tests/classes/property_recreate_private.phpt b/tests/classes/property_recreate_private.phpt index b37b974845..6d25d71912 100644 --- a/tests/classes/property_recreate_private.phpt +++ b/tests/classes/property_recreate_private.phpt @@ -5,10 +5,10 @@ Unsetting and recreating private properties. class C { private $p = 'test'; function unsetPrivate() { - unset($this->p); + unset($this->p); } function setPrivate() { - $this->p = 'changed'; + $this->p = 'changed'; } } diff --git a/tests/classes/property_recreate_protected.phpt b/tests/classes/property_recreate_protected.phpt index 3319640e3a..ddbbb71fc9 100644 --- a/tests/classes/property_recreate_protected.phpt +++ b/tests/classes/property_recreate_protected.phpt @@ -5,10 +5,10 @@ Unsetting and recreating protected properties. class C { protected $p = 'test'; function unsetProtected() { - unset($this->p); + unset($this->p); } function setProtected() { - $this->p = 'changed'; + $this->p = 'changed'; } } diff --git a/tests/classes/static_mix_1.phpt b/tests/classes/static_mix_1.phpt index 71db59663f..70740d2336 100644 --- a/tests/classes/static_mix_1.phpt +++ b/tests/classes/static_mix_1.phpt @@ -19,6 +19,6 @@ pass::show(); fail::show(); echo "Done\n"; // shouldn't be displayed -?> +?> --EXPECTF-- Fatal error: Cannot make static method pass::show() non static in class fail in %s on line %d diff --git a/tests/classes/static_properties_003.phpt b/tests/classes/static_properties_003.phpt index 2aab44d586..89c26d3dd3 100644 --- a/tests/classes/static_properties_003.phpt +++ b/tests/classes/static_properties_003.phpt @@ -1,5 +1,5 @@ --TEST-- -Attempting to access static properties using instance property syntax +Attempting to access static properties using instance property syntax --FILE-- <?php class C { diff --git a/tests/classes/static_properties_003_error1.phpt b/tests/classes/static_properties_003_error1.phpt index df297a71b2..68a57a8f89 100644 --- a/tests/classes/static_properties_003_error1.phpt +++ b/tests/classes/static_properties_003_error1.phpt @@ -1,5 +1,5 @@ --TEST-- -Attempting to access static properties using instance property syntax +Attempting to access static properties using instance property syntax --FILE-- <?php class C { diff --git a/tests/classes/static_properties_003_error2.phpt b/tests/classes/static_properties_003_error2.phpt index 4509568160..b428b4ff6e 100644 --- a/tests/classes/static_properties_003_error2.phpt +++ b/tests/classes/static_properties_003_error2.phpt @@ -1,5 +1,5 @@ --TEST-- -Attempting to access static properties using instance property syntax +Attempting to access static properties using instance property syntax --FILE-- <?php class C { diff --git a/tests/classes/static_properties_003_error3.phpt b/tests/classes/static_properties_003_error3.phpt index 4f4288a63c..b9423639b0 100644 --- a/tests/classes/static_properties_003_error3.phpt +++ b/tests/classes/static_properties_003_error3.phpt @@ -1,5 +1,5 @@ --TEST-- -Attempting to access static properties using instance property syntax +Attempting to access static properties using instance property syntax --FILE-- <?php class C { diff --git a/tests/classes/static_properties_003_error4.phpt b/tests/classes/static_properties_003_error4.phpt index b43753f1c5..6501689ddb 100644 --- a/tests/classes/static_properties_003_error4.phpt +++ b/tests/classes/static_properties_003_error4.phpt @@ -1,5 +1,5 @@ --TEST-- -Attempting to access static properties using instance property syntax +Attempting to access static properties using instance property syntax --FILE-- <?php class C { @@ -8,7 +8,7 @@ class C { $c = new C; echo "\n--> Access non-visible static prop like instance prop:\n"; -$c->y =& $ref; +$c->y =& $ref; ?> ==Done== --EXPECTF-- diff --git a/tests/classes/static_properties_004.phpt b/tests/classes/static_properties_004.phpt index 79bbc6380b..42860c3301 100644 --- a/tests/classes/static_properties_004.phpt +++ b/tests/classes/static_properties_004.phpt @@ -1,5 +1,5 @@ --TEST-- -Inherited static properties cannot be separated from their reference set. +Inherited static properties cannot be separated from their reference set. --FILE-- <?php class C { public static $p = 'original'; } diff --git a/tests/classes/this.phpt b/tests/classes/this.phpt index 5551e8ac88..30ea83e285 100644 --- a/tests/classes/this.phpt +++ b/tests/classes/this.phpt @@ -3,7 +3,7 @@ ZE2 $this cannot be exchanged --FILE-- <?php -/* please don't shorten this test. It shows what would happen if +/* please don't shorten this test. It shows what would happen if * the fatal error would have been a warning. */ class Foo diff --git a/tests/classes/tostring_002.phpt b/tests/classes/tostring_002.phpt index 627cbb359c..7dda92339e 100644 --- a/tests/classes/tostring_002.phpt +++ b/tests/classes/tostring_002.phpt @@ -9,7 +9,7 @@ class Test { return "Hello\n"; } - + function __destruct() { echo $this; diff --git a/tests/classes/tostring_003.phpt b/tests/classes/tostring_003.phpt index 096a7502fe..e3bc7f8f2c 100644 --- a/tests/classes/tostring_003.phpt +++ b/tests/classes/tostring_003.phpt @@ -10,7 +10,7 @@ class Test throw new Exception("Damn!"); return "Hello\n"; } - + function __destruct() { echo $this; diff --git a/tests/classes/tostring_004.phpt b/tests/classes/tostring_004.phpt index fffc1f8635..bfaa57e36f 100644 --- a/tests/classes/tostring_004.phpt +++ b/tests/classes/tostring_004.phpt @@ -23,7 +23,7 @@ echo "\n\nObject with bad __toString():\n"; class badToString { function __toString() { return 0; - } + } } $obj = new badToString; echo "Try 1:\n"; diff --git a/tests/classes/unset_properties.phpt b/tests/classes/unset_properties.phpt index 8683155e35..e19a7d92d5 100644 --- a/tests/classes/unset_properties.phpt +++ b/tests/classes/unset_properties.phpt @@ -11,29 +11,29 @@ class Test protected $protectedProperty = 'protectedProperty set'; private $privateProperty = 'privateProperty set'; - + public function __get($name) { return '__get "' . $name . '"'; } - + public function __set($name, $value) { $this->$name = $value; echo '__set "' . $name . '" to "' . $value . '"'; } - + public function __isset($name) { echo '__isset "' . $name . '"'; return isset($this->$name); } - + public function getPublicProperty() { return $this->publicProperty; } - + public function setPublicProperty($publicProperty) { $this->publicProperty = $publicProperty; diff --git a/tests/func/002.phpt b/tests/func/002.phpt index cb35f92043..4319715e08 100644 --- a/tests/func/002.phpt +++ b/tests/func/002.phpt @@ -1,14 +1,14 @@ --TEST-- Static variables in functions --FILE-- -<?php +<?php function blah() { static $hey=0,$yo=0; echo "hey=".$hey++.", ",$yo--."\n"; } - + blah(); blah(); blah(); diff --git a/tests/func/003.phpt b/tests/func/003.phpt index d603784076..1135009e21 100644 --- a/tests/func/003.phpt +++ b/tests/func/003.phpt @@ -1,7 +1,7 @@ --TEST-- General function test --FILE-- -<?php +<?php function a() { diff --git a/tests/func/004.phpt b/tests/func/004.phpt index 1434297b0d..79c891a223 100644 --- a/tests/func/004.phpt +++ b/tests/func/004.phpt @@ -1,7 +1,7 @@ --TEST-- General function test --FILE-- -<?php +<?php echo "Before function declaration...\n"; diff --git a/tests/func/005.phpt b/tests/func/005.phpt index c4215feb49..e19eda496b 100644 --- a/tests/func/005.phpt +++ b/tests/func/005.phpt @@ -1,7 +1,7 @@ --TEST-- Testing register_shutdown_function() --FILE-- -<?php +<?php function foo() { diff --git a/tests/func/005a.phpt b/tests/func/005a.phpt index 3c2bcb1665..8cd0d211ab 100644 --- a/tests/func/005a.phpt +++ b/tests/func/005a.phpt @@ -8,7 +8,7 @@ if (getenv("SKIP_SLOW_TESTS")) die("skip slow test"); <?php ini_set('display_errors', 0); - + echo "Start\n"; function boo() @@ -19,7 +19,7 @@ function boo() register_shutdown_function("boo"); /* not necessary, just to show the error sooner */ -set_time_limit(1); +set_time_limit(1); /* infinite loop to simulate long processing */ for (;;) {} diff --git a/tests/func/007.phpt b/tests/func/007.phpt index 73aae2e649..6a18d444ee 100644 --- a/tests/func/007.phpt +++ b/tests/func/007.phpt @@ -3,11 +3,11 @@ INI functions test --FILE-- <?php -$ini1 = ini_get('include_path'); +$ini1 = ini_get('include_path'); ini_set('include_path','ini_set_works'); echo ini_get('include_path')."\n"; ini_restore('include_path'); -$ini2 = ini_get('include_path'); +$ini2 = ini_get('include_path'); if ($ini1 !== $ini2) { echo "ini_restore() does not work.\n"; diff --git a/tests/lang/002.phpt b/tests/lang/002.phpt index ec14d01c3f..251f90b0a2 100644 --- a/tests/lang/002.phpt +++ b/tests/lang/002.phpt @@ -2,7 +2,7 @@ Simple While Loop Test --FILE-- <?php -$a=1; +$a=1; while ($a<10) { echo $a; $a++; diff --git a/tests/lang/003.phpt b/tests/lang/003.phpt index 7049db9047..a580fc60cd 100644 --- a/tests/lang/003.phpt +++ b/tests/lang/003.phpt @@ -2,10 +2,10 @@ Simple Switch Test --FILE-- <?php -$a=1; +$a=1; switch($a) { case 0: - echo "bad"; + echo "bad"; break; case 1: echo "good"; diff --git a/tests/lang/004.phpt b/tests/lang/004.phpt index be8ebf4155..9ca3492cde 100644 --- a/tests/lang/004.phpt +++ b/tests/lang/004.phpt @@ -2,12 +2,12 @@ Simple If/Else Test --FILE-- <?php -$a=1; +$a=1; if($a==0) { echo "bad"; } else { echo "good"; } -?> +?> --EXPECT-- good diff --git a/tests/lang/005.phpt b/tests/lang/005.phpt index 404a7cbbf6..fe3633b58b 100644 --- a/tests/lang/005.phpt +++ b/tests/lang/005.phpt @@ -2,7 +2,7 @@ Simple If/ElseIf/Else Test --FILE-- <?php -$a=1; +$a=1; if($a==0) { echo "bad"; @@ -11,6 +11,6 @@ if($a==0) { } else { echo "good"; } -?> +?> --EXPECT-- good diff --git a/tests/lang/006.phpt b/tests/lang/006.phpt index 2a2db013ab..5056b8a4ee 100644 --- a/tests/lang/006.phpt +++ b/tests/lang/006.phpt @@ -18,6 +18,6 @@ if($a==0) { echo "bad"; } } -?> +?> --EXPECT-- good diff --git a/tests/lang/007.phpt b/tests/lang/007.phpt index 4576d4efa5..946ae9babb 100644 --- a/tests/lang/007.phpt +++ b/tests/lang/007.phpt @@ -17,9 +17,9 @@ function Test() echo "$a $c "; } -Test(); +Test(); echo "$a $b $c "; -Test(); +Test(); echo "$a $b $c "; Test(); ?> diff --git a/tests/lang/008.phpt b/tests/lang/008.phpt index d335e6f135..8633b6049a 100644 --- a/tests/lang/008.phpt +++ b/tests/lang/008.phpt @@ -6,7 +6,7 @@ Testing recursive function function Test() { static $a=1; - echo "$a "; + echo "$a "; $a++; if($a<10): Test(); endif; } diff --git a/tests/lang/009.phpt b/tests/lang/009.phpt index ea2aa9294d..8621a73e50 100644 --- a/tests/lang/009.phpt +++ b/tests/lang/009.phpt @@ -3,7 +3,7 @@ Testing function parameter passing --FILE-- <?php function test ($a,$b) { - echo $a+$b; + echo $a+$b; } test(1,2); ?> diff --git a/tests/lang/011.phpt b/tests/lang/011.phpt index 771ef7c129..b7946b7460 100644 --- a/tests/lang/011.phpt +++ b/tests/lang/011.phpt @@ -1,7 +1,7 @@ --TEST-- Testing nested functions --FILE-- -<?php +<?php function F() { $a = "Hello "; @@ -11,7 +11,7 @@ function F() function G() { static $myvar = 4; - + echo "$myvar "; echo F(); echo "$myvar"; diff --git a/tests/lang/012.phpt b/tests/lang/012.phpt index 117137a29b..203d7cebe3 100644 --- a/tests/lang/012.phpt +++ b/tests/lang/012.phpt @@ -1,8 +1,8 @@ --TEST-- Testing stack after early function return --FILE-- -<?php -function F () { +<?php +function F () { if(1) { return("Hello"); } diff --git a/tests/lang/013.phpt b/tests/lang/013.phpt index be84cdcb8f..c25cf41abe 100644 --- a/tests/lang/013.phpt +++ b/tests/lang/013.phpt @@ -1,7 +1,7 @@ --TEST-- Testing eval function --FILE-- -<?php +<?php error_reporting(0); $a="echo \"Hello\";"; eval($a); diff --git a/tests/lang/014.phpt b/tests/lang/014.phpt index f0033b2f77..fe6f86e22a 100644 --- a/tests/lang/014.phpt +++ b/tests/lang/014.phpt @@ -1,8 +1,8 @@ --TEST-- Testing eval function inside user-defined function --FILE-- -<?php -function F ($a) { +<?php +function F ($a) { eval($a); } diff --git a/tests/lang/016.phpt b/tests/lang/016.phpt index dbaa908b81..30c36b3d2a 100644 --- a/tests/lang/016.phpt +++ b/tests/lang/016.phpt @@ -1,7 +1,7 @@ --TEST-- Testing user-defined function in included file --FILE-- -<?php +<?php include "016.inc"; MyFunc("Hello"); ?> diff --git a/tests/lang/018.phpt b/tests/lang/018.phpt index 638b131c2d..7560219291 100644 --- a/tests/lang/018.phpt +++ b/tests/lang/018.phpt @@ -1,7 +1,7 @@ --TEST-- eval() test --FILE-- -<?php +<?php error_reporting(0); diff --git a/tests/lang/019.phpt b/tests/lang/019.phpt index c9b5e5f3b5..313da0cbd8 100644 --- a/tests/lang/019.phpt +++ b/tests/lang/019.phpt @@ -1,7 +1,7 @@ --TEST-- eval() test --FILE-- -<?php +<?php eval("function test() { echo \"hey, this is a function inside an eval()!\\n\"; }"); diff --git a/tests/lang/020.phpt b/tests/lang/020.phpt index 46a2a2c1c0..9428ec5e6f 100644 --- a/tests/lang/020.phpt +++ b/tests/lang/020.phpt @@ -1,7 +1,7 @@ --TEST-- Switch test 1 --FILE-- -<?php +<?php $i="abc"; diff --git a/tests/lang/021.phpt b/tests/lang/021.phpt index aff45b6be3..438f873da5 100644 --- a/tests/lang/021.phpt +++ b/tests/lang/021.phpt @@ -1,12 +1,12 @@ --TEST-- Switch test 2 --FILE-- -<?php +<?php for ($i=0; $i<=5; $i++) { echo "i=$i\n"; - + switch($i) { case 0: echo "In branch 0\n"; diff --git a/tests/lang/022.phpt b/tests/lang/022.phpt index dddc6c2955..9660530bc7 100644 --- a/tests/lang/022.phpt +++ b/tests/lang/022.phpt @@ -1,7 +1,7 @@ --TEST-- Switch test 3 --FILE-- -<?php +<?php function switchtest ($i, $j) { @@ -11,7 +11,7 @@ function switchtest ($i, $j) case 0: echo "zero"; break; - case 1: + case 1: echo "one"; break; default: diff --git a/tests/lang/025.phpt b/tests/lang/025.phpt index 382960f628..13c02d31d4 100644 --- a/tests/lang/025.phpt +++ b/tests/lang/025.phpt @@ -1,7 +1,7 @@ --TEST-- Mean recursion test --FILE-- -<?php +<?php function RekTest ($nr) { echo " $nr "; $j=$nr+1; diff --git a/tests/lang/027.phpt b/tests/lang/027.phpt index d3eb74b22f..9c826cfe93 100644 --- a/tests/lang/027.phpt +++ b/tests/lang/027.phpt @@ -1,7 +1,7 @@ --TEST-- Testing do-while loop --FILE-- -<?php +<?php $i=3; do { echo $i; diff --git a/tests/lang/028.phpt b/tests/lang/028.phpt index 2c51b79cb2..0c2f2f0756 100644 --- a/tests/lang/028.phpt +++ b/tests/lang/028.phpt @@ -19,7 +19,7 @@ function still_working() function dafna() { static $foo = 0; - + print "Dafna!\n"; print call_user_func("still_working")."\n"; $foo++; diff --git a/tests/lang/034.phpt b/tests/lang/034.phpt index 5d2c610926..38ecc0b451 100644 --- a/tests/lang/034.phpt +++ b/tests/lang/034.phpt @@ -9,7 +9,7 @@ if (setlocale(LC_NUMERIC, "de_DE.UTF-8", "de_DE", "de", "german", "ge", "de_DE.I } ?> --FILE-- -<?php +<?php # activate the german locale setlocale(LC_NUMERIC, "de_DE.UTF-8", "de_DE", "de", "german", "ge", "de_DE.ISO-8859-1"); diff --git a/tests/lang/035.phpt b/tests/lang/035.phpt index 63f0385e8c..bc49af99a5 100644 --- a/tests/lang/035.phpt +++ b/tests/lang/035.phpt @@ -4,18 +4,18 @@ ZE2: set_exception_handler() <?php class MyException extends Exception { function __construct($_error) { - $this->error = $_error; + $this->error = $_error; } - + function getException() { - return $this->error; + return $this->error; } } function ThrowException() { - throw new MyException("'This is an exception!'"); + throw new MyException("'This is an exception!'"); } @@ -26,7 +26,7 @@ try { } try { - ThrowException(); + ThrowException(); } catch (MyException $exception) { print "There was an exception: " . $exception->getException(); print "\n"; diff --git a/tests/lang/bug18872.phpt b/tests/lang/bug18872.phpt index 2e3dc22c58..5e5333879d 100644 --- a/tests/lang/bug18872.phpt +++ b/tests/lang/bug18872.phpt @@ -1,18 +1,18 @@ --TEST-- Bug #18872 (class constant used as default parameter) --FILE-- -<?php -class FooBar { - const BIFF = 3; -} - -function foo($biff = FooBar::BIFF) { - echo $biff . "\n"; -} - -foo(); -foo(); -?> +<?php +class FooBar { + const BIFF = 3; +} + +function foo($biff = FooBar::BIFF) { + echo $biff . "\n"; +} + +foo(); +foo(); +?> --EXPECT-- 3 3 diff --git a/tests/lang/bug20175.phpt b/tests/lang/bug20175.phpt index a42e35c41e..0d040c82d9 100644 --- a/tests/lang/bug20175.phpt +++ b/tests/lang/bug20175.phpt @@ -33,7 +33,7 @@ function foo_static() { /* Part 2: * Storing a reference to the result of a function in a static variable. * Same as Part 1 but: - * The return statement transports a copy of the value to return. In other + * The return statement transports a copy of the value to return. In other * words the return value of bar_global() is a temporary variable only valid * after the function call bar_global() is done in current local scope. */ @@ -83,8 +83,8 @@ function wow_static() { /* Part 4: * Storing a reference to a new instance (that's where the name of the test - * comes from). First there is the global counter $oop_global again which - * counts the calls to the constructor of oop_class and hence counts the + * comes from). First there is the global counter $oop_global again which + * counts the calls to the constructor of oop_class and hence counts the * creation of oop_class instances. * The class oop_test uses a static reference to a oop_class instance. * When another oop_test instance is created it must reuse the statically @@ -94,7 +94,7 @@ function wow_static() { $oop_global = 0; class oop_class { var $oop_name; - + function __construct() { global $oop_global; echo "oop_class()\n"; @@ -104,11 +104,11 @@ class oop_class { class oop_test { static $oop_value; - + function __construct() { echo "oop_test()\n"; } - + function oop_static() { echo "oop_static()\n"; if (!isset(self::$oop_value)) { diff --git a/tests/lang/bug21094.phpt b/tests/lang/bug21094.phpt index 266a1d6c8f..ac3ae2a2c7 100644 --- a/tests/lang/bug21094.phpt +++ b/tests/lang/bug21094.phpt @@ -6,7 +6,7 @@ class test { function hdlr($errno, $errstr, $errfile, $errline) { printf("[%d] errstr: %s, errfile: %s, errline: %d\n", $errno, $errstr, $errfile, $errline, $errstr); } -} +} set_error_handler(array(new test(), "hdlr")); diff --git a/tests/lang/bug21849.phpt b/tests/lang/bug21849.phpt index 2ce99769d9..def754a3a6 100644 --- a/tests/lang/bug21849.phpt +++ b/tests/lang/bug21849.phpt @@ -4,7 +4,7 @@ Bug #21849 (self::constant doesn't work as method's default parameter) <?php class foo { const bar = "fubar\n"; - + function __construct($arg = self::bar) { echo $arg; } diff --git a/tests/lang/bug22510.phpt b/tests/lang/bug22510.phpt index c625ea7ddd..dbf7756daa 100644 --- a/tests/lang/bug22510.phpt +++ b/tests/lang/bug22510.phpt @@ -4,7 +4,7 @@ Bug #22510 (segfault among complex references) error_reporting=E_ALL | E_DEPRECATED --FILE-- <?php -class foo +class foo { public $list = array(); @@ -29,7 +29,7 @@ class foo } } -class bar +class bar { function run1() { print __CLASS__."::".__FUNCTION__."\n"; @@ -66,7 +66,7 @@ function ok1(&$bar) { function ok2(&$bar) { print __FUNCTION__."\n"; - @$a = $a; + @$a = $a; $bar->run2(); } diff --git a/tests/lang/bug23384.phpt b/tests/lang/bug23384.phpt index 2c41217b90..2dc3f2308b 100644 --- a/tests/lang/bug23384.phpt +++ b/tests/lang/bug23384.phpt @@ -15,7 +15,7 @@ class Foo { } } -Foo::test(); +Foo::test(); echo Foo::HUN."\n"; ?> --EXPECTF-- diff --git a/tests/lang/bug24396.phpt b/tests/lang/bug24396.phpt index 80862191de..bb5c83860a 100644 --- a/tests/lang/bug24396.phpt +++ b/tests/lang/bug24396.phpt @@ -7,10 +7,10 @@ $arr = array('a' => 1, 'b' => 2, 'c' => 3); foreach($arr as $k=>$v) { global $$k; // comment this out and it works in PHP 7 too.. - + echo "($k => $v)\n"; - - $$k = $v; + + $$k = $v; } ?> --EXPECT-- diff --git a/tests/lang/bug24908.phpt b/tests/lang/bug24908.phpt index 30056abf3c..910b715a05 100644 --- a/tests/lang/bug24908.phpt +++ b/tests/lang/bug24908.phpt @@ -4,7 +4,7 @@ Bug #24908 (super-globals can not be used in __destruct()) variables_order=GPS --FILE-- <?php -class test { +class test { function __construct() { if (count($_SERVER)) echo "O"; } diff --git a/tests/lang/bug24926.phpt b/tests/lang/bug24926.phpt index e7fd86ce76..f73d265f38 100644 --- a/tests/lang/bug24926.phpt +++ b/tests/lang/bug24926.phpt @@ -8,15 +8,15 @@ error_reporting (E_ALL); class foo { public $functions = array(); - + function __construct() { $function = create_function('', 'return "FOO\n";'); print($function()); - + $this->functions['test'] = $function; print($this->functions['test']()); // werkt al niet meer - + } } diff --git a/tests/lang/bug24951.phpt b/tests/lang/bug24951.phpt index aa48ab2936..5538e13815 100644 --- a/tests/lang/bug24951.phpt +++ b/tests/lang/bug24951.phpt @@ -31,7 +31,7 @@ function t3() } t1(); echo "\n"; -t2(); echo "\n"; +t2(); echo "\n"; t3(); echo "\n"; ?> --EXPECT-- diff --git a/tests/lang/bug25652.phpt b/tests/lang/bug25652.phpt index 09cfc18197..b0125de085 100644 --- a/tests/lang/bug25652.phpt +++ b/tests/lang/bug25652.phpt @@ -6,17 +6,17 @@ Bug #25652 (Calling Global functions dynamically fails from Class scope) function testfunc ($var) { echo "testfunc $var\n"; } - + class foo { public $arr = array('testfunc'); function bar () { $this->arr[0]('testvalue'); } } - + $a = new foo (); $a->bar (); - + ?> --EXPECT-- testfunc testvalue diff --git a/tests/lang/bug25922.phpt b/tests/lang/bug25922.phpt index bb030c9df8..41fb135e03 100644 --- a/tests/lang/bug25922.phpt +++ b/tests/lang/bug25922.phpt @@ -9,7 +9,7 @@ function my_error_handler($error, $errmsg='', $errfile='', $errline=0, $errconte echo "$errmsg\n"; $errcontext = ''; } - + set_error_handler('my_error_handler'); function test() diff --git a/tests/lang/bug26696.phpt b/tests/lang/bug26696.phpt index dae182d307..a73694c95a 100644 --- a/tests/lang/bug26696.phpt +++ b/tests/lang/bug26696.phpt @@ -14,7 +14,7 @@ for ($i = 0; $i < $len; $i++) { } $str = '*'; -switch ($str[0]) { +switch ($str[0]) { case '*'; echo "OK\n"; break; diff --git a/tests/lang/bug27535.phpt b/tests/lang/bug27535.phpt index 29fd033469..604b2d3d04 100644 --- a/tests/lang/bug27535.phpt +++ b/tests/lang/bug27535.phpt @@ -2,7 +2,7 @@ Bug #27535 (Objects pointing to each other cause Apache to crash) --FILE-- <?php - + class Class1 { public $_Class2_obj; diff --git a/tests/lang/bug29893.phpt b/tests/lang/bug29893.phpt index d320de0ee7..25679893d2 100644 --- a/tests/lang/bug29893.phpt +++ b/tests/lang/bug29893.phpt @@ -3,7 +3,7 @@ Bug #29893 (segfault when using array as index) --FILE-- <?php $base = 50; -$base[$base] -= 0; +$base[$base] -= 0; ?> ===DONE=== --EXPECTF-- diff --git a/tests/lang/bug29944.phpt b/tests/lang/bug29944.phpt index 7882936f08..80a76f132e 100644 --- a/tests/lang/bug29944.phpt +++ b/tests/lang/bug29944.phpt @@ -11,7 +11,7 @@ switch ($a) { return false; } echo foo($b); -} +} ?> ===DONE=== diff --git a/tests/lang/bug30578.phpt b/tests/lang/bug30578.phpt index d8a8d2e54f..dc9eeeaae4 100644 --- a/tests/lang/bug30578.phpt +++ b/tests/lang/bug30578.phpt @@ -1,5 +1,5 @@ --TEST-- -Bug #30578 (Output buffers flushed before calling __desctruct functions) +Bug #30578 (Output buffers flushed before calling __desctruct functions) --FILE-- <?php diff --git a/tests/lang/bug30638.phpt b/tests/lang/bug30638.phpt index 30b70f30fb..24e6609498 100644 --- a/tests/lang/bug30638.phpt +++ b/tests/lang/bug30638.phpt @@ -9,7 +9,7 @@ if (setlocale(LC_NUMERIC, "de_DE.UTF-8", "de_DE", "de", "german", "ge", "de_DE.I } ?> --FILE-- -<?php +<?php # activate the german locale setlocale(LC_NUMERIC, "de_DE.UTF-8", "de_DE", "de", "german", "ge", "de_DE.ISO-8859-1"); diff --git a/tests/lang/bug30862.phpt b/tests/lang/bug30862.phpt index 12c95d57e8..7f2d3ed4ae 100644 --- a/tests/lang/bug30862.phpt +++ b/tests/lang/bug30862.phpt @@ -1,7 +1,7 @@ --TEST-- Bug #30862 (Static array with boolean indexes) --FILE-- -<?php +<?php class T { static $a = array(false=>"false", true=>"true"); } diff --git a/tests/lang/bug32828.phpt b/tests/lang/bug32828.phpt index 4abf21604f..b5772afc52 100644 --- a/tests/lang/bug32828.phpt +++ b/tests/lang/bug32828.phpt @@ -12,7 +12,7 @@ ob_start('output_handler'); ob_end_clean(); ?> ---EXPECTF-- +--EXPECTF-- Fatal error: Uncaught Exception in %s:%d Stack trace: #0 [internal function]: output_handler('', %d) diff --git a/tests/lang/bug32924.phpt b/tests/lang/bug32924.phpt index d72b0eaa2e..4c6dab0a16 100644 --- a/tests/lang/bug32924.phpt +++ b/tests/lang/bug32924.phpt @@ -4,7 +4,7 @@ Bug #32924 (prepend does not add file to included files) include_path={PWD} auto_prepend_file=inc.inc --FILE-- -<?php +<?php include_once(dirname(__FILE__).'/inc.inc'); require_once(dirname(__FILE__).'/inc.inc'); ?> diff --git a/tests/lang/bug44827.phpt b/tests/lang/bug44827.phpt index 031045b083..90bf1d8893 100644 --- a/tests/lang/bug44827.phpt +++ b/tests/lang/bug44827.phpt @@ -1,7 +1,7 @@ --TEST-- Bug #44827 (Class error when trying to access :: as constant) --CREDITS-- -Sebastian Schürmann +Sebastian Schürmann sebs@php.net Testfest Munich 2009 --FILE-- diff --git a/tests/lang/bug45392.phpt b/tests/lang/bug45392.phpt index 78876c7c80..a9bdd40af2 100644 --- a/tests/lang/bug45392.phpt +++ b/tests/lang/bug45392.phpt @@ -6,7 +6,7 @@ display_errors=stderr <?php if (getenv("USE_ZEND_ALLOC") === "0") { die("skip Zend MM disabled"); -} +} --FILE-- <?php echo __LINE__ . "\n"; diff --git a/tests/lang/compare_objects_basic1.phpt b/tests/lang/compare_objects_basic1.phpt index 07ebd7cc69..e54fb2173e 100644 --- a/tests/lang/compare_objects_basic1.phpt +++ b/tests/lang/compare_objects_basic1.phpt @@ -1,5 +1,5 @@ --TEST-- -Test standard 'compare' object handler +Test standard 'compare' object handler --FILE-- <?php @@ -31,10 +31,10 @@ $obj3 = new class3(); $obj4 = new class4(); $obj5 = new class5(); -echo "\n-- The following compare should return TRUE --\n"; +echo "\n-- The following compare should return TRUE --\n"; var_dump($obj1 == $obj1); -echo "\n-- All the following compares should return FALSE --\n"; +echo "\n-- All the following compares should return FALSE --\n"; var_dump($obj1 == $obj2); var_dump($obj1 == $obj3); var_dump($obj1 == $obj4); diff --git a/tests/lang/compare_objects_basic2.phpt b/tests/lang/compare_objects_basic2.phpt index e822f1e4ee..c38dbcec42 100644 --- a/tests/lang/compare_objects_basic2.phpt +++ b/tests/lang/compare_objects_basic2.phpt @@ -1,10 +1,10 @@ --TEST-- -Test object compare when object handler different +Test object compare when object handler different --FILE-- -<?php +<?php -//Set the default time zone +//Set the default time zone date_default_timezone_set("Europe/London"); echo "Simple test comparing two objects with different compare callback handler\n"; diff --git a/tests/lang/engine_assignExecutionOrder_001.phpt b/tests/lang/engine_assignExecutionOrder_001.phpt index 627e69ffc5..f5140b54e2 100644 --- a/tests/lang/engine_assignExecutionOrder_001.phpt +++ b/tests/lang/engine_assignExecutionOrder_001.phpt @@ -14,7 +14,7 @@ function g() { } -echo "\n\nOrder with local assignment:\n"; +echo "\n\nOrder with local assignment:\n"; ${f()} = g(); var_dump($name); @@ -42,7 +42,7 @@ var_dump($oc); class C { public static $name = "original"; - public static $a = array(); + public static $a = array(); public static $string = "hello"; } echo "\n\nOrder with static property assignment:\n"; @@ -55,7 +55,7 @@ var_dump(C::$a); echo "\n\nOrder with indexed string assignment:\n"; $string = "hello"; -function getOffset() { +function getOffset() { echo "in getOffset()\n"; return 0; } diff --git a/tests/lang/engine_assignExecutionOrder_002.phpt b/tests/lang/engine_assignExecutionOrder_002.phpt index c090a452c3..dbb0c0aba4 100644 --- a/tests/lang/engine_assignExecutionOrder_002.phpt +++ b/tests/lang/engine_assignExecutionOrder_002.phpt @@ -28,7 +28,7 @@ $g3 = array(30,30); $g = array($g1,$g2,$g3); list($e[$f++],$e[$f++]) = $g[2]; // expect 30,30 -var_dump($e); +var_dump($e); $i1 = array(1,2); @@ -38,7 +38,7 @@ $i4 = array(array(1000,2000),3000); $i = array($i1,$i2,$i3,$i4); $j = array(0,0,0); $h = 0; -// a list of lists +// a list of lists list(list($j[$h++],$j[$h++]),$j[$h++]) = $i[3]; var_dump($j); @@ -50,7 +50,7 @@ list(list($l,$m),$n) = $k; echo "L=$l M=$m N=$n\n"; -// expect $x and $y to be null - this fails on php.net 5.2.1 (invalid opcode) - fixed in 5.2.3 +// expect $x and $y to be null - this fails on php.net 5.2.1 (invalid opcode) - fixed in 5.2.3 list($o,$p) = 20; echo "O=$o and P=$p\n"; @@ -65,7 +65,7 @@ list(list(list($r,$s,,$t),list($u,$v),,$w),,$x) = $q4; echo "$r $s $t $u $v $w $x\n"; -// expect y and z to be undefined +// expect y and z to be undefined list($y,$z) = array(); echo "Y=$y,Z=$z\n"; @@ -77,7 +77,7 @@ echo "AA=$aa\n"; list($cc,,$dd) = array(10,20,30,40); echo "CC=$cc DD=$dd\n"; -// expect the inner array to be defined +// expect the inner array to be defined $ee = array("original array"); function f() { global $ee; diff --git a/tests/lang/engine_assignExecutionOrder_003.phpt b/tests/lang/engine_assignExecutionOrder_003.phpt index 448b46e8ec..6a9c7f38e3 100644 --- a/tests/lang/engine_assignExecutionOrder_003.phpt +++ b/tests/lang/engine_assignExecutionOrder_003.phpt @@ -5,7 +5,7 @@ Evaluation order during assignments. $b = "bb"; $a = "aa"; -function foo() +function foo() { echo "Bad call\n"; } @@ -75,7 +75,7 @@ $x2 = array(array(2),2); $x3 = array(array(3),3); $bx = array(10); -$x[mod($x1)][mod($x2)] = $bx[mod($x3)]; +$x[mod($x1)][mod($x2)] = $bx[mod($x3)]; // expecting 10,3 diff --git a/tests/lang/engine_assignExecutionOrder_007.phpt b/tests/lang/engine_assignExecutionOrder_007.phpt index d66773f024..14a2a812b1 100644 --- a/tests/lang/engine_assignExecutionOrder_007.phpt +++ b/tests/lang/engine_assignExecutionOrder_007.phpt @@ -1,5 +1,5 @@ --TEST-- -Check key execution order with new. +Check key execution order with new. --FILE-- <?php $a[2][3] = 'stdClass'; diff --git a/tests/lang/engine_assignExecutionOrder_009.phpt b/tests/lang/engine_assignExecutionOrder_009.phpt index 62b3327e06..5401ecc287 100644 --- a/tests/lang/engine_assignExecutionOrder_009.phpt +++ b/tests/lang/engine_assignExecutionOrder_009.phpt @@ -8,18 +8,18 @@ function f($x) { } echo "Function call args:\n"; -var_dump(f($i=0) < f(++$i)); +var_dump(f($i=0) < f(++$i)); var_dump(f($i=0) <= f(++$i)); -var_dump(f($i=0) > f(++$i)); +var_dump(f($i=0) > f(++$i)); var_dump(f($i=0) >= f(++$i)); echo "\nArray indices:\n"; $a[1][2] = 0; $a[3][4] = 1; $i=0; -var_dump($a[$i=1][++$i] < $a[++$i][++$i]); +var_dump($a[$i=1][++$i] < $a[++$i][++$i]); var_dump($a[$i=1][++$i] <= $a[++$i][++$i]); -var_dump($a[$i=1][++$i] > $a[++$i][++$i]); +var_dump($a[$i=1][++$i] > $a[++$i][++$i]); var_dump($a[$i=1][++$i] >= $a[++$i][++$i]); ?> --EXPECT-- diff --git a/tests/lang/error_2_exception_001.phpt b/tests/lang/error_2_exception_001.phpt index e084b92dd7..6ef3a52676 100644 --- a/tests/lang/error_2_exception_001.phpt +++ b/tests/lang/error_2_exception_001.phpt @@ -12,7 +12,7 @@ class MyException extends Exception { function getErrno() { return $this->errno; } - + function getErrmsg() { return $this->errmsg; } diff --git a/tests/lang/execution_order.phpt b/tests/lang/execution_order.phpt index ca3feb32cb..27424c41b9 100644 --- a/tests/lang/execution_order.phpt +++ b/tests/lang/execution_order.phpt @@ -169,7 +169,7 @@ echo "\r\n"; echo "24)"; echo ($c->val=300) + $c->val; echo "\r\n"; - + ?> --EXPECT-- 1)goodgood diff --git a/tests/lang/foreachLoop.002.phpt b/tests/lang/foreachLoop.002.phpt index 31492953a4..5b92736e5d 100644 --- a/tests/lang/foreachLoop.002.phpt +++ b/tests/lang/foreachLoop.002.phpt @@ -35,7 +35,7 @@ foreach ($a as $v) { //avoid infinite loop if test is failing if ($counter++>10) { echo "Loop detected\n"; - break; + break; } } var_dump($a); @@ -49,8 +49,8 @@ foreach ($a as &$v) { //avoid infinite loop if test is failing if ($counter++>10) { echo "Loop detected\n"; - break; - } + break; + } } var_dump($a); @@ -58,7 +58,7 @@ echo "\nPopping elements off an unreferenced array.\n"; $a = array("original.1","original.2","original.3"); foreach ($a as $v) { array_pop($a); - var_dump($v); + var_dump($v); } var_dump($a); diff --git a/tests/lang/foreachLoop.009.phpt b/tests/lang/foreachLoop.009.phpt index 90aa33953b..37b0163358 100644 --- a/tests/lang/foreachLoop.009.phpt +++ b/tests/lang/foreachLoop.009.phpt @@ -28,7 +28,7 @@ $count=0; foreach ($refedArray as $k=>$v3) { array_push($refedArray, "new.$k"); echo "key: $k; value: $v3\n"; - + if ($count++>5) { echo "Loop detected, as expected.\n"; break; @@ -42,7 +42,7 @@ $count=0; foreach ($refedArray as $k=>&$v4) { array_push($refedArray, "new.$k"); echo "key: $k; value: $v4\n"; - + if ($count++>5) { echo "Loop detected, as expected.\n"; break; diff --git a/tests/lang/foreachLoop.010.phpt b/tests/lang/foreachLoop.010.phpt index 2ff0a7b61f..e114e839b9 100644 --- a/tests/lang/foreachLoop.010.phpt +++ b/tests/lang/foreachLoop.010.phpt @@ -7,26 +7,26 @@ It will pass only if the 'contentious code' in PHPValue.decReferences() is enabl $a = array(1,2,3); $container = array(&$a); -// From php.net: +// From php.net: // "Unless the array is referenced, foreach operates on a copy of // the specified array and not the array itself." // At this point, the array $a is referenced. // The following line ensures $a is no longer references as a consequence -// of running the 'destructor' on $container. +// of running the 'destructor' on $container. $container = null; // At this point the array $a is no longer referenced, so foreach should operate on a copy of the array. // However, P8 does not invoke 'destructors' when refcount is decremented to 0. // Consequently, $a thinks it is still referenced, and foreach will operate on the array itself. // This provokes a difference in behaviour when changing the number of elements in the array while -// iterating over it. +// iterating over it. $i=0; foreach ($a as $v) { array_push($a, 'new'); var_dump($v); - + if (++$i>10) { echo "Infinite loop detected\n"; break; diff --git a/tests/lang/foreachLoop.011.phpt b/tests/lang/foreachLoop.011.phpt index eeb08596cb..1f57e0acdf 100644 --- a/tests/lang/foreachLoop.011.phpt +++ b/tests/lang/foreachLoop.011.phpt @@ -1,5 +1,5 @@ ---TEST-- -Changing from an interable type to a non iterable type during the iteration +--TEST-- +Changing from an interable type to a non iterable type during the iteration --FILE-- <?php echo "\nChange from array to non iterable:\n"; @@ -17,7 +17,7 @@ $a->b=2; $b=&$a; foreach ($a as $v) { var_dump($v); - $b='x'; + $b='x'; } ?> diff --git a/tests/lang/foreachLoop.012.phpt b/tests/lang/foreachLoop.012.phpt index be72ae0e30..b308e9ff57 100644 --- a/tests/lang/foreachLoop.012.phpt +++ b/tests/lang/foreachLoop.012.phpt @@ -12,11 +12,11 @@ function withRefValue($elements, $transform) { $a[] = "v.$i"; } $counter=0; - + echo "--> State of array before loop:\n"; var_dump($a); - - echo "--> Do loop:\n"; + + echo "--> Do loop:\n"; foreach ($a as $k=>$v) { echo " iteration $counter: \$k=$k; \$v=$v\n"; eval($transform); @@ -26,7 +26,7 @@ function withRefValue($elements, $transform) { break; } } - + echo "--> State of array after loop:\n"; var_dump($a); } diff --git a/tests/lang/foreachLoop.013.phpt b/tests/lang/foreachLoop.013.phpt index cd1e0af96e..e53130da00 100644 --- a/tests/lang/foreachLoop.013.phpt +++ b/tests/lang/foreachLoop.013.phpt @@ -12,11 +12,11 @@ function withRefValue($elements, $transform) { $a[] = "v.$i"; } $counter=0; - + echo "--> State of array before loop:\n"; var_dump($a); - - echo "--> Do loop:\n"; + + echo "--> Do loop:\n"; foreach ($a as $k=>&$v) { echo " iteration $counter: \$k=$k; \$v=$v\n"; eval($transform); @@ -26,7 +26,7 @@ function withRefValue($elements, $transform) { break; } } - + echo "--> State of array after loop:\n"; var_dump($a); } diff --git a/tests/lang/foreachLoop.014.phpt b/tests/lang/foreachLoop.014.phpt index 9d45eb8244..9db3470e9c 100644 --- a/tests/lang/foreachLoop.014.phpt +++ b/tests/lang/foreachLoop.014.phpt @@ -12,13 +12,13 @@ function withRefValue($elements, $transform) { $a[] = "v.$i"; } $counter=0; - + $ref = &$a; - + echo "--> State of referenced array before loop:\n"; var_dump($a); - - echo "--> Do loop:\n"; + + echo "--> Do loop:\n"; foreach ($a as $k=>$v) { echo " iteration $counter: \$k=$k; \$v=$v\n"; eval($transform); @@ -28,7 +28,7 @@ function withRefValue($elements, $transform) { break; } } - + echo "--> State of array after loop:\n"; var_dump($a); } diff --git a/tests/lang/foreachLoop.015.phpt b/tests/lang/foreachLoop.015.phpt index 13333ccf4d..876c867512 100644 --- a/tests/lang/foreachLoop.015.phpt +++ b/tests/lang/foreachLoop.015.phpt @@ -12,13 +12,13 @@ function withRefValue($elements, $transform) { $a[] = "v.$i"; } $counter=0; - + $ref = &$a; - + echo "--> State of referenced array before loop:\n"; var_dump($a); - - echo "--> Do loop:\n"; + + echo "--> Do loop:\n"; foreach ($a as $k=>&$v) { echo " iteration $counter: \$k=$k; \$v=$v\n"; eval($transform); @@ -28,7 +28,7 @@ function withRefValue($elements, $transform) { break; } } - + echo "--> State of array after loop:\n"; var_dump($a); } diff --git a/tests/lang/foreachLoop.016.phpt b/tests/lang/foreachLoop.016.phpt index 60af401580..01c44449a7 100644 --- a/tests/lang/foreachLoop.016.phpt +++ b/tests/lang/foreachLoop.016.phpt @@ -10,7 +10,7 @@ Ensure foreach splits the iterated entity from its cow reference set, for all so } var_dump($b); unset($a, $b); - + echo "\n" . '${\'a\'}' . "\n"; $b = $a = array('original'); foreach(${'a'} as $k=>&$v) { @@ -18,7 +18,7 @@ Ensure foreach splits the iterated entity from its cow reference set, for all so } var_dump($b); unset($a, $b); - + echo "\n" . '$$a' . "\n"; $a = 'blah'; $$a = array('original'); @@ -28,7 +28,7 @@ Ensure foreach splits the iterated entity from its cow reference set, for all so } var_dump($b); unset($a, $b); - + echo "\n" . '$a[0]' . "\n"; $b = $a[0] = array('original'); foreach($a[0] as $k=>&$v) { @@ -36,7 +36,7 @@ Ensure foreach splits the iterated entity from its cow reference set, for all so } var_dump($b); unset($a, $b); - + echo "\n" . '$a[0][0]' . "\n"; $b = $a[0][0] = array('original'); foreach($a[0][0] as $k=>&$v) { @@ -44,7 +44,7 @@ Ensure foreach splits the iterated entity from its cow reference set, for all so } var_dump($b); unset($a, $b); - + echo "\n" . '$a->b' . "\n"; $b = $a->b = array('original'); foreach($a->b as $k=>&$v) { @@ -52,7 +52,7 @@ Ensure foreach splits the iterated entity from its cow reference set, for all so } var_dump($b); unset($a, $b); - + echo "\n" . '$a->b->c' . "\n"; $b = $a->b->c = array('original'); foreach($a->b as $k=>&$v) { @@ -60,7 +60,7 @@ Ensure foreach splits the iterated entity from its cow reference set, for all so } var_dump($b); unset($a, $b); - + echo "\n" . '$a->b[0]' . "\n"; $b = $a->b[0] = array('original'); foreach($a->b[0] as $k=>&$v) { @@ -68,7 +68,7 @@ Ensure foreach splits the iterated entity from its cow reference set, for all so } var_dump($b); unset($a, $b); - + echo "\n" . '$a->b[0][0]' . "\n"; $b = $a->b[0][0] = array('original'); foreach($a->b[0][0] as $k=>&$v) { @@ -76,7 +76,7 @@ Ensure foreach splits the iterated entity from its cow reference set, for all so } var_dump($b); unset($a, $b); - + echo "\n" . '$a->b[0]->c' . "\n"; $b = $a->b[0]->c = array('original'); foreach($a->b[0]->c as $k=>&$v) { @@ -84,11 +84,11 @@ Ensure foreach splits the iterated entity from its cow reference set, for all so } var_dump($b); unset($a, $b); - + class C { public static $a; } - + echo "\n" . 'C::$a' . "\n"; C::$a = array('original'); $b = C::$a; @@ -97,7 +97,7 @@ Ensure foreach splits the iterated entity from its cow reference set, for all so } var_dump($b); unset($a, $b); - + echo "\n" . 'C::$a[0]' . "\n"; C::$a[0] = array('original'); $b = C::$a[0]; @@ -106,7 +106,7 @@ Ensure foreach splits the iterated entity from its cow reference set, for all so } var_dump($b); unset(C::$a[0], $b); - + echo "\n" . 'C::$a[0]->b' . "\n"; C::$a[0]->b = array('original'); $b = C::$a[0]->b; diff --git a/tests/lang/foreachLoop.017.phpt b/tests/lang/foreachLoop.017.phpt index bbc21adaa3..d68a82cc4c 100644 --- a/tests/lang/foreachLoop.017.phpt +++ b/tests/lang/foreachLoop.017.phpt @@ -5,7 +5,7 @@ Ensure foreach works with arrays with Binary keys. $a = array ( "\x90" => 10 ); foreach ($a as $val=>$key) echo $key; echo "\nDone\n"; -?> +?> --EXPECT-- 10 Done diff --git a/tests/lang/foreachLoopIterator.001.phpt b/tests/lang/foreachLoopIterator.001.phpt index cba3827451..61fffc617a 100644 --- a/tests/lang/foreachLoopIterator.001.phpt +++ b/tests/lang/foreachLoopIterator.001.phpt @@ -1,24 +1,24 @@ --TEST-- -foreach with Iterator. +foreach with Iterator. --FILE-- <?php class MealIterator implements Iterator { private $pos=0; private $myContent=array("breakfast", "lunch", "dinner"); - + public function valid() { global $indent; echo "$indent--> " . __METHOD__ . " ($this->pos)\n"; return $this->pos<3; } - + public function next() { global $indent; echo "$indent--> " . __METHOD__ . " ($this->pos)\n"; return $this->myContent[$this->pos++]; } - + public function rewind() { global $indent; echo "$indent--> " . __METHOD__ . " ($this->pos)\n"; @@ -30,13 +30,13 @@ class MealIterator implements Iterator { echo "$indent--> " . __METHOD__ . " ($this->pos)\n"; return $this->myContent[$this->pos]; } - + public function key() { global $indent; echo "$indent--> " . __METHOD__ . " ($this->pos)\n"; return "meal " . $this->pos; } - + } $f = new MealIterator; @@ -44,7 +44,7 @@ var_dump($f); echo "-----( Simple iteration: )-----\n"; foreach ($f as $k=>$v) { - echo "$k => $v\n"; + echo "$k => $v\n"; } $f->rewind(); @@ -54,14 +54,14 @@ $indent = " "; echo "\n\n\n-----( Nested iteration: )-----\n"; $count=1; foreach ($f as $k=>$v) { - echo "\nTop level " . $count++ . ": \n"; + echo "\nTop level " . $count++ . ": \n"; echo "$k => $v\n"; $indent = " "; foreach ($f as $k=>$v) { - echo " $k => $v\n"; + echo " $k => $v\n"; } $indent = " "; - + } ?> diff --git a/tests/lang/foreachLoopIterator.002.phpt b/tests/lang/foreachLoopIterator.002.phpt index a016dba2b6..fe38145c3b 100644 --- a/tests/lang/foreachLoopIterator.002.phpt +++ b/tests/lang/foreachLoopIterator.002.phpt @@ -14,7 +14,7 @@ class MyIterator implements Iterator { $f = new MyIterator; echo "-----( Try to iterate with &\$value: )-----\n"; foreach ($f as $k=>&$v) { - echo "$k => $v\n"; + echo "$k => $v\n"; } ?> diff --git a/tests/lang/foreachLoopIteratorAggregate.001.phpt b/tests/lang/foreachLoopIteratorAggregate.001.phpt index 094fc3b8bb..47baeab42c 100644 --- a/tests/lang/foreachLoopIteratorAggregate.001.phpt +++ b/tests/lang/foreachLoopIteratorAggregate.001.phpt @@ -5,19 +5,19 @@ foreach with iteratorAggregate class EnglishMealIterator implements Iterator { private $pos=0; private $myContent=array("breakfast", "dinner", "tea"); - + public function valid() { global $indent; echo "$indent--> " . __METHOD__ . " ($this->pos)\n"; return $this->pos < count($this->myContent); } - + public function next() { global $indent; echo "$indent--> " . __METHOD__ . " ($this->pos)\n"; $this->pos++; } - + public function rewind() { global $indent; echo "$indent--> " . __METHOD__ . " ($this->pos)\n"; @@ -29,31 +29,31 @@ class EnglishMealIterator implements Iterator { echo "$indent--> " . __METHOD__ . " ($this->pos)\n"; return $this->myContent[$this->pos]; } - + public function key() { global $indent; echo "$indent--> " . __METHOD__ . " ($this->pos)\n"; return "meal " . $this->pos; } - + } class FrenchMealIterator implements Iterator { private $pos=0; private $myContent=array("petit dejeuner", "dejeuner", "gouter", "dinner"); - + public function valid() { global $indent; echo "$indent--> " . __METHOD__ . " ($this->pos)\n"; return $this->pos < count($this->myContent); } - + public function next() { global $indent; echo "$indent--> " . __METHOD__ . " ($this->pos)\n"; $this->pos++; } - + public function rewind() { global $indent; echo "$indent--> " . __METHOD__ . " ($this->pos)\n"; @@ -65,30 +65,30 @@ class FrenchMealIterator implements Iterator { echo "$indent--> " . __METHOD__ . " ($this->pos)\n"; return $this->myContent[$this->pos]; } - + public function key() { global $indent; echo "$indent--> " . __METHOD__ . " ($this->pos)\n"; return "meal " . $this->pos; } - + } Class EuropeanMeals implements IteratorAggregate { - + private $storedEnglishMealIterator; private $storedFrenchMealIterator; - + public function __construct() { $this->storedEnglishMealIterator = new EnglishMealIterator; $this->storedFrenchMealIterator = new FrenchMealIterator; } - + public function getIterator() { global $indent; echo "$indent--> " . __METHOD__ . "\n"; - + //Alternate between English and French meals static $i = 0; if ($i++%2 == 0) { @@ -97,7 +97,7 @@ Class EuropeanMeals implements IteratorAggregate { return $this->storedFrenchMealIterator; } } - + } $f = new EuropeanMeals; @@ -105,11 +105,11 @@ var_dump($f); echo "-----( Simple iteration 1: )-----\n"; foreach ($f as $k=>$v) { - echo "$k => $v\n"; + echo "$k => $v\n"; } echo "-----( Simple iteration 2: )-----\n"; foreach ($f as $k=>$v) { - echo "$k => $v\n"; + echo "$k => $v\n"; } @@ -117,11 +117,11 @@ $indent = " "; echo "\n\n\n-----( Nested iteration: )-----\n"; $count=1; foreach ($f as $k=>$v) { - echo "\nTop level " . $count++ . ": \n"; + echo "\nTop level " . $count++ . ": \n"; echo "$k => $v\n"; $indent = " "; foreach ($f as $k=>$v) { - echo " $k => $v\n"; + echo " $k => $v\n"; } $indent = " "; } diff --git a/tests/lang/foreachLoopIteratorAggregate.002.phpt b/tests/lang/foreachLoopIteratorAggregate.002.phpt index 23f04feed2..d4b8d2f2da 100644 --- a/tests/lang/foreachLoopIteratorAggregate.002.phpt +++ b/tests/lang/foreachLoopIteratorAggregate.002.phpt @@ -31,7 +31,7 @@ class bad4 implements IteratorAggregate { function f($className) { try { foreach (new $className as $k=>$v) { - echo "$k => $v\n"; + echo "$k => $v\n"; } } catch (Exception $e) { echo $e->getLine() . ": " . $e->getMessage() ."\n"; diff --git a/tests/lang/foreachLoopIteratorAggregate.003.phpt b/tests/lang/foreachLoopIteratorAggregate.003.phpt index cb3586c005..adc8fe5351 100644 --- a/tests/lang/foreachLoopIteratorAggregate.003.phpt +++ b/tests/lang/foreachLoopIteratorAggregate.003.phpt @@ -5,19 +5,19 @@ foreach with nested iteratorAggregates class EnglishMealIterator implements Iterator { private $pos=0; private $myContent=array("breakfast", "dinner", "tea"); - + public function valid() { global $indent; echo "$indent--> " . __METHOD__ . " ($this->pos)\n"; return $this->pos<3; } - + public function next() { global $indent; echo "$indent--> " . __METHOD__ . " ($this->pos)\n"; return $this->myContent[$this->pos++]; } - + public function rewind() { global $indent; echo "$indent--> " . __METHOD__ . " ($this->pos)\n"; @@ -29,13 +29,13 @@ class EnglishMealIterator implements Iterator { echo "$indent--> " . __METHOD__ . " ($this->pos)\n"; return $this->myContent[$this->pos]; } - + public function key() { global $indent; echo "$indent--> " . __METHOD__ . " ($this->pos)\n"; return "meal " . $this->pos; } - + } class A1 implements IteratorAggregate { @@ -58,17 +58,17 @@ class A3 implements IteratorAggregate { echo "\n-----( A1: )-----\n"; foreach (new A1 as $k=>$v) { - echo "$k => $v\n"; + echo "$k => $v\n"; } echo "\n-----( A2: )-----\n"; foreach (new A2 as $k=>$v) { - echo "$k => $v\n"; + echo "$k => $v\n"; } echo "\n-----( A3: )-----\n"; foreach (new A3 as $k=>$v) { - echo "$k => $v\n"; + echo "$k => $v\n"; } ?> diff --git a/tests/lang/foreachLoopIteratorAggregate.004.phpt b/tests/lang/foreachLoopIteratorAggregate.004.phpt index 9a1e612c23..30c422b2c8 100644 --- a/tests/lang/foreachLoopIteratorAggregate.004.phpt +++ b/tests/lang/foreachLoopIteratorAggregate.004.phpt @@ -40,7 +40,7 @@ class c_iter implements Iterator { function __destruct() { } } - + class c implements IteratorAggregate { public $max = 3; diff --git a/tests/lang/foreachLoopObjects.001.phpt b/tests/lang/foreachLoopObjects.001.phpt index 985a00784a..93eeaadc6a 100644 --- a/tests/lang/foreachLoopObjects.001.phpt +++ b/tests/lang/foreachLoopObjects.001.phpt @@ -9,7 +9,7 @@ class C { public $c = "Original c"; protected $d = "Original d"; private $e = "Original e"; - + } echo "\n\nSimple loop.\n"; diff --git a/tests/lang/foreachLoopObjects.002.phpt b/tests/lang/foreachLoopObjects.002.phpt index 6961f69078..e1e96c86f0 100644 --- a/tests/lang/foreachLoopObjects.002.phpt +++ b/tests/lang/foreachLoopObjects.002.phpt @@ -17,7 +17,7 @@ class C { $v="changed.$k"; } } - + static function doForEach($obj) { echo "in C::doForEach\n"; foreach ($obj as $k=>&$v) { @@ -25,7 +25,7 @@ class C { $v="changed.$k"; } } - + function doForEachOnThis() { echo "in C::doForEachOnThis\n"; foreach ($this as $k=>&$v) { @@ -33,14 +33,14 @@ class C { $v="changed.$k"; } } - + } class D extends C { - + private $f = "Original f"; protected $g = "Original g"; - + static function doForEach($obj) { echo "in D::doForEach\n"; foreach ($obj as $k=>&$v) { @@ -63,7 +63,7 @@ class E extends D { public $b = "Overridden b"; public $c = "Overridden c"; protected $d = "Overridden d"; - private $e = "Overridden e"; + private $e = "Overridden e"; static function doForEach($obj) { echo "in E::doForEach\n"; diff --git a/tests/lang/foreachLoopObjects.003.phpt b/tests/lang/foreachLoopObjects.003.phpt index c90342364f..0d0e073eb6 100644 --- a/tests/lang/foreachLoopObjects.003.phpt +++ b/tests/lang/foreachLoopObjects.003.phpt @@ -44,7 +44,7 @@ foreach ($obj as $v) { echo "Loop detected\n"; break; } - var_dump($v); + var_dump($v); } var_dump($obj); @@ -56,9 +56,9 @@ foreach ($obj as &$v) { $obj->$newPropName = "Added property $counter"; if ($counter++>10) { echo "Loop detected\n"; - break; + break; } - var_dump($v); + var_dump($v); } var_dump($obj); @@ -67,7 +67,7 @@ $obj = new C; foreach ($obj as $v) { unset($obj->a); unset($obj->b); - unset($obj->c); + unset($obj->c); var_dump($v); } var_dump($obj); diff --git a/tests/lang/foreachLoopObjects.004.phpt b/tests/lang/foreachLoopObjects.004.phpt index c6cadad0f0..01e4e9fd9a 100644 --- a/tests/lang/foreachLoopObjects.004.phpt +++ b/tests/lang/foreachLoopObjects.004.phpt @@ -16,13 +16,13 @@ $obj = new C; $count=0; foreach ($obj as $v) { if ($v==$obj->b) { - unset($obj->b); + unset($obj->b); } var_dump($v); if (++$count>10) { echo "Loop detected.\n"; break; - } + } } var_dump($obj); diff --git a/tests/lang/foreachLoopObjects.005.phpt b/tests/lang/foreachLoopObjects.005.phpt index 1692bcd2fc..624d9ad10c 100644 --- a/tests/lang/foreachLoopObjects.005.phpt +++ b/tests/lang/foreachLoopObjects.005.phpt @@ -16,13 +16,13 @@ $obj = new C; $count=0; foreach ($obj as $v) { if ($v==$obj->a) { - unset($obj->c); + unset($obj->c); } var_dump($v); if (++$count>10) { echo "Loop detected.\n"; break; - } + } } var_dump($obj); @@ -30,13 +30,13 @@ echo "\nRemoving properties before the current element from an iterated object.\ $obj = new C; foreach ($obj as $v) { if ($v==$obj->b) { - unset($obj->a); + unset($obj->a); } var_dump($v); if (++$count>10) { echo "Loop detected.\n"; break; - } + } } var_dump($obj); diff --git a/tests/lang/foreachLoopObjects.006.phpt b/tests/lang/foreachLoopObjects.006.phpt index 5204aca9ca..3e9b73542a 100644 --- a/tests/lang/foreachLoopObjects.006.phpt +++ b/tests/lang/foreachLoopObjects.006.phpt @@ -30,7 +30,7 @@ foreach ($obj as $v) { if (++$count>10) { echo "Loop detected.\n"; break; - } + } } var_dump($obj); @@ -47,7 +47,7 @@ foreach ($obj as $v) { if (++$count>10) { echo "Loop detected.\n"; break; - } + } } var_dump($obj); diff --git a/tests/lang/func_get_arg.002.phpt b/tests/lang/func_get_arg.002.phpt index 6ab4f95719..5b80ec1773 100644 --- a/tests/lang/func_get_arg.002.phpt +++ b/tests/lang/func_get_arg.002.phpt @@ -9,7 +9,7 @@ function foo($a) var_dump($b); $b++; var_dump(func_get_arg(1)); - + } foo(2, 3); echo "\n"; diff --git a/tests/lang/func_get_arg.004.phpt b/tests/lang/func_get_arg.004.phpt index 5afe4c95eb..0a4547ec18 100644 --- a/tests/lang/func_get_arg.004.phpt +++ b/tests/lang/func_get_arg.004.phpt @@ -5,7 +5,7 @@ func_get_arg on non-existent arg function foo($a) { - var_dump(func_get_arg(2)); + var_dump(func_get_arg(2)); } foo(2, 3); echo "\n"; diff --git a/tests/lang/func_get_arg.005.phpt b/tests/lang/func_get_arg.005.phpt index 9da14eb6f3..5dd5468721 100644 --- a/tests/lang/func_get_arg.005.phpt +++ b/tests/lang/func_get_arg.005.phpt @@ -1,6 +1,6 @@ --TEST-- A variable, which is referenced by another variable, is passed by value. -During the call, the original variable is updated. This should not affect func_get_arg(). +During the call, the original variable is updated. This should not affect func_get_arg(). --FILE-- <?php function refVal($x) { diff --git a/tests/lang/func_get_args.001.phpt b/tests/lang/func_get_args.001.phpt index 40083aeb37..a17cfb3d19 100644 --- a/tests/lang/func_get_args.001.phpt +++ b/tests/lang/func_get_args.001.phpt @@ -5,7 +5,7 @@ func_get_args with no args function foo() { - var_dump(func_get_args()); + var_dump(func_get_args()); } foo(); diff --git a/tests/lang/func_get_args.002.phpt b/tests/lang/func_get_args.002.phpt index 0a886c2f04..ea78d99a2b 100644 --- a/tests/lang/func_get_args.002.phpt +++ b/tests/lang/func_get_args.002.phpt @@ -5,7 +5,7 @@ func_get_args with variable number of args function foo($a) { - var_dump(func_get_args()); + var_dump(func_get_args()); } foo(1, 2, 3); diff --git a/tests/lang/func_get_args.003.phpt b/tests/lang/func_get_args.003.phpt index 44faf7ebf8..844288d904 100644 --- a/tests/lang/func_get_args.003.phpt +++ b/tests/lang/func_get_args.003.phpt @@ -3,7 +3,7 @@ func_get_args() outside of a function declaration --FILE-- <?php -var_dump(func_get_args()); +var_dump(func_get_args()); ?> --EXPECTREGEX-- diff --git a/tests/lang/func_num_args.001.phpt b/tests/lang/func_num_args.001.phpt index 117e8d0e06..5d7a91d25e 100644 --- a/tests/lang/func_num_args.001.phpt +++ b/tests/lang/func_num_args.001.phpt @@ -5,7 +5,7 @@ func_num_args with no args function foo() { - var_dump(func_num_args()); + var_dump(func_num_args()); } foo(); diff --git a/tests/lang/func_num_args.002.phpt b/tests/lang/func_num_args.002.phpt index 45246a7684..8586fad735 100644 --- a/tests/lang/func_num_args.002.phpt +++ b/tests/lang/func_num_args.002.phpt @@ -5,7 +5,7 @@ func_num_args with variable number of args function foo($a) { - var_dump(func_num_args()); + var_dump(func_num_args()); } foo(1, 2, 3); diff --git a/tests/lang/func_num_args.003.phpt b/tests/lang/func_num_args.003.phpt index dceabbd096..168f79d04e 100644 --- a/tests/lang/func_num_args.003.phpt +++ b/tests/lang/func_num_args.003.phpt @@ -3,7 +3,7 @@ func_num_args() outside of a function declaration --FILE-- <?php -var_dump(func_num_args()); +var_dump(func_num_args()); ?> --EXPECTF-- diff --git a/tests/lang/func_num_args.004.phpt b/tests/lang/func_num_args.004.phpt index d8142c9e7e..aef61668a4 100644 --- a/tests/lang/func_num_args.004.phpt +++ b/tests/lang/func_num_args.004.phpt @@ -1,5 +1,5 @@ --TEST-- -Pass same variable by ref and by value. +Pass same variable by ref and by value. --FILE-- <?php function valRef($x, &$y) { diff --git a/tests/lang/operators/add_basiclong_64bit.phpt b/tests/lang/operators/add_basiclong_64bit.phpt index eb55d5f210..0168843494 100644 --- a/tests/lang/operators/add_basiclong_64bit.phpt +++ b/tests/lang/operators/add_basiclong_64bit.phpt @@ -6,7 +6,7 @@ if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only"); ?> --FILE-- <?php - + define("MAX_64Bit", 9223372036854775807); define("MAX_32Bit", 2147483647); define("MIN_64Bit", -9223372036854775807 - 1); @@ -14,7 +14,7 @@ define("MIN_32Bit", -2147483647 - 1); $longVals = array( MAX_64Bit, MIN_64Bit, MAX_32Bit, MIN_32Bit, MAX_64Bit - MAX_32Bit, MIN_64Bit - MIN_32Bit, - MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1, + MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1, MAX_64Bit -1, MAX_64Bit + 1, MIN_64Bit + 1, MIN_64Bit - 1 ); @@ -24,18 +24,18 @@ error_reporting(E_ERROR); foreach ($longVals as $longVal) { foreach($otherVals as $otherVal) { - echo "--- testing: $longVal + $otherVal ---\n"; + echo "--- testing: $longVal + $otherVal ---\n"; var_dump($longVal+$otherVal); } } foreach ($otherVals as $otherVal) { foreach($longVals as $longVal) { - echo "--- testing: $otherVal + $longVal ---\n"; + echo "--- testing: $otherVal + $longVal ---\n"; var_dump($otherVal+$longVal); } } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/add_variationStr.phpt b/tests/lang/operators/add_variationStr.phpt index 9bf11ec698..cc5834c578 100644 --- a/tests/lang/operators/add_variationStr.phpt +++ b/tests/lang/operators/add_variationStr.phpt @@ -12,12 +12,12 @@ error_reporting(E_ERROR); foreach ($strVals as $strVal) { foreach($strVals as $otherVal) { - echo "--- testing: '$strVal' + '$otherVal' ---\n"; + echo "--- testing: '$strVal' + '$otherVal' ---\n"; var_dump($strVal+$otherVal); } } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/bitwiseAnd_basiclong_64bit.phpt b/tests/lang/operators/bitwiseAnd_basiclong_64bit.phpt index 5dc322873a..30bdcf4c60 100644 --- a/tests/lang/operators/bitwiseAnd_basiclong_64bit.phpt +++ b/tests/lang/operators/bitwiseAnd_basiclong_64bit.phpt @@ -6,7 +6,7 @@ if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only"); ?> --FILE-- <?php - + define("MAX_64Bit", 9223372036854775807); define("MAX_32Bit", 2147483647); define("MIN_64Bit", -9223372036854775807 - 1); @@ -14,7 +14,7 @@ define("MIN_32Bit", -2147483647 - 1); $longVals = array( MAX_64Bit, MIN_64Bit, MAX_32Bit, MIN_32Bit, MAX_64Bit - MAX_32Bit, MIN_64Bit - MIN_32Bit, - MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1, + MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1, MAX_64Bit -1, MAX_64Bit + 1, MIN_64Bit + 1, MIN_64Bit - 1 ); @@ -24,18 +24,18 @@ error_reporting(E_ERROR); foreach ($longVals as $longVal) { foreach($otherVals as $otherVal) { - echo "--- testing: $longVal & $otherVal ---\n"; + echo "--- testing: $longVal & $otherVal ---\n"; var_dump($longVal&$otherVal); } } foreach ($otherVals as $otherVal) { foreach($longVals as $longVal) { - echo "--- testing: $otherVal & $longVal ---\n"; + echo "--- testing: $otherVal & $longVal ---\n"; var_dump($otherVal&$longVal); } } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/bitwiseAnd_variationStr.phpt b/tests/lang/operators/bitwiseAnd_variationStr.phpt index 5b7cb10b12..50ddb9ddb5 100644 --- a/tests/lang/operators/bitwiseAnd_variationStr.phpt +++ b/tests/lang/operators/bitwiseAnd_variationStr.phpt @@ -12,12 +12,12 @@ error_reporting(E_ERROR); foreach ($strVals as $strVal) { foreach($strVals as $otherVal) { - echo "--- testing: '$strVal' & '$otherVal' ---\n"; + echo "--- testing: '$strVal' & '$otherVal' ---\n"; var_dump(bin2hex($strVal&$otherVal)); } } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/bitwiseNot_basiclong_64bit.phpt b/tests/lang/operators/bitwiseNot_basiclong_64bit.phpt index 86df2d771d..5b8d7c9c48 100644 --- a/tests/lang/operators/bitwiseNot_basiclong_64bit.phpt +++ b/tests/lang/operators/bitwiseNot_basiclong_64bit.phpt @@ -6,7 +6,7 @@ if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only"); ?> --FILE-- <?php - + define("MAX_64Bit", 9223372036854775807); define("MAX_32Bit", 2147483647); define("MIN_64Bit", -9223372036854775807 - 1); @@ -14,7 +14,7 @@ define("MIN_32Bit", -2147483647 - 1); $longVals = array( MAX_64Bit, MIN_64Bit, MAX_32Bit, MIN_32Bit, MAX_64Bit - MAX_32Bit, MIN_64Bit - MIN_32Bit, - MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1, + MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1, MAX_64Bit -1, MAX_64Bit + 1, MIN_64Bit + 1, MIN_64Bit - 1 ); @@ -23,7 +23,7 @@ foreach ($longVals as $longVal) { echo "--- testing: $longVal ---\n"; var_dump(~$longVal); } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/bitwiseNot_variationStr.phpt b/tests/lang/operators/bitwiseNot_variationStr.phpt index 98bca9e473..d0f8a75933 100644 --- a/tests/lang/operators/bitwiseNot_variationStr.phpt +++ b/tests/lang/operators/bitwiseNot_variationStr.phpt @@ -13,7 +13,7 @@ foreach ($strVals as $strVal) { echo "--- testing: '$strVal' ---\n"; var_dump(bin2hex(~$strVal)); } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/bitwiseOr_basiclong_64bit.phpt b/tests/lang/operators/bitwiseOr_basiclong_64bit.phpt index 50e35a1c28..dc4126cb0c 100644 --- a/tests/lang/operators/bitwiseOr_basiclong_64bit.phpt +++ b/tests/lang/operators/bitwiseOr_basiclong_64bit.phpt @@ -6,7 +6,7 @@ if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only"); ?> --FILE-- <?php - + define("MAX_64Bit", 9223372036854775807); define("MAX_32Bit", 2147483647); define("MIN_64Bit", -9223372036854775807 - 1); @@ -14,7 +14,7 @@ define("MIN_32Bit", -2147483647 - 1); $longVals = array( MAX_64Bit, MIN_64Bit, MAX_32Bit, MIN_32Bit, MAX_64Bit - MAX_32Bit, MIN_64Bit - MIN_32Bit, - MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1, + MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1, MAX_64Bit -1, MAX_64Bit + 1, MIN_64Bit + 1, MIN_64Bit - 1 ); @@ -24,18 +24,18 @@ error_reporting(E_ERROR); foreach ($longVals as $longVal) { foreach($otherVals as $otherVal) { - echo "--- testing: $longVal | $otherVal ---\n"; + echo "--- testing: $longVal | $otherVal ---\n"; var_dump($longVal|$otherVal); } } foreach ($otherVals as $otherVal) { foreach($longVals as $longVal) { - echo "--- testing: $otherVal | $longVal ---\n"; + echo "--- testing: $otherVal | $longVal ---\n"; var_dump($otherVal|$longVal); } } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/bitwiseOr_variationStr.phpt b/tests/lang/operators/bitwiseOr_variationStr.phpt index 2d1d353788..a883c4687a 100644 --- a/tests/lang/operators/bitwiseOr_variationStr.phpt +++ b/tests/lang/operators/bitwiseOr_variationStr.phpt @@ -12,12 +12,12 @@ error_reporting(E_ERROR); foreach ($strVals as $strVal) { foreach($strVals as $otherVal) { - echo "--- testing: '$strVal' | '$otherVal' ---\n"; + echo "--- testing: '$strVal' | '$otherVal' ---\n"; var_dump(bin2hex($strVal|$otherVal)); } } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/bitwiseShiftLeft_basiclong_64bit.phpt b/tests/lang/operators/bitwiseShiftLeft_basiclong_64bit.phpt index 99626da6f1..218abf9d7a 100644 --- a/tests/lang/operators/bitwiseShiftLeft_basiclong_64bit.phpt +++ b/tests/lang/operators/bitwiseShiftLeft_basiclong_64bit.phpt @@ -6,7 +6,7 @@ if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only"); ?> --FILE-- <?php - + define("MAX_64Bit", 9223372036854775807); define("MAX_32Bit", 2147483647); define("MIN_64Bit", -9223372036854775807 - 1); @@ -14,7 +14,7 @@ define("MIN_32Bit", -2147483647 - 1); $longVals = array( MAX_64Bit, MIN_64Bit, MAX_32Bit, MIN_32Bit, MAX_64Bit - MAX_32Bit, MIN_64Bit - MIN_32Bit, - MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1, + MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1, MAX_64Bit -1, MAX_64Bit + 1, MIN_64Bit + 1, MIN_64Bit - 1 ); @@ -43,7 +43,7 @@ foreach ($otherVals as $otherVal) { } } } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/bitwiseShiftLeft_variationStr.phpt b/tests/lang/operators/bitwiseShiftLeft_variationStr.phpt index 7300eca02c..1f66dfce4c 100644 --- a/tests/lang/operators/bitwiseShiftLeft_variationStr.phpt +++ b/tests/lang/operators/bitwiseShiftLeft_variationStr.phpt @@ -20,7 +20,7 @@ foreach ($strVals as $strVal) { } } } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/bitwiseShiftLeft_variationStr_64bit.phpt b/tests/lang/operators/bitwiseShiftLeft_variationStr_64bit.phpt index ddfd2f7c6d..c36e22fef4 100644 --- a/tests/lang/operators/bitwiseShiftLeft_variationStr_64bit.phpt +++ b/tests/lang/operators/bitwiseShiftLeft_variationStr_64bit.phpt @@ -17,7 +17,7 @@ error_reporting(E_ERROR); foreach ($strVals as $strVal) { foreach($strVals as $otherVal) { echo "--- testing: '$strVal' << '$otherVal' ---\n"; - try { + try { var_dump($strVal<<$otherVal); } catch (ArithmeticError $e) { echo "Exception: " . $e->getMessage() . "\n"; @@ -25,7 +25,7 @@ foreach ($strVals as $strVal) { } } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/bitwiseShiftRight_basiclong_64bit.phpt b/tests/lang/operators/bitwiseShiftRight_basiclong_64bit.phpt index 65e7e826b8..7a08ed09da 100644 --- a/tests/lang/operators/bitwiseShiftRight_basiclong_64bit.phpt +++ b/tests/lang/operators/bitwiseShiftRight_basiclong_64bit.phpt @@ -6,7 +6,7 @@ if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only"); ?> --FILE-- <?php - + define("MAX_64Bit", 9223372036854775807); define("MAX_32Bit", 2147483647); define("MIN_64Bit", -9223372036854775807 - 1); @@ -14,7 +14,7 @@ define("MIN_32Bit", -2147483647 - 1); $longVals = array( MAX_64Bit, MIN_64Bit, MAX_32Bit, MIN_32Bit, MAX_64Bit - MAX_32Bit, MIN_64Bit - MIN_32Bit, - MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1, + MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1, MAX_64Bit -1, MAX_64Bit + 1, MIN_64Bit + 1, MIN_64Bit - 1 ); @@ -43,7 +43,7 @@ foreach ($otherVals as $otherVal) { } } } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/bitwiseShiftRight_variationStr.phpt b/tests/lang/operators/bitwiseShiftRight_variationStr.phpt index a4c425aab3..e3c9c8962d 100644 --- a/tests/lang/operators/bitwiseShiftRight_variationStr.phpt +++ b/tests/lang/operators/bitwiseShiftRight_variationStr.phpt @@ -21,7 +21,7 @@ foreach ($strVals as $strVal) { } } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/bitwiseXor_basiclong_64bit.phpt b/tests/lang/operators/bitwiseXor_basiclong_64bit.phpt index 0bfd8089e6..1b63f38dee 100644 --- a/tests/lang/operators/bitwiseXor_basiclong_64bit.phpt +++ b/tests/lang/operators/bitwiseXor_basiclong_64bit.phpt @@ -6,7 +6,7 @@ if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only"); ?> --FILE-- <?php - + define("MAX_64Bit", 9223372036854775807); define("MAX_32Bit", 2147483647); define("MIN_64Bit", -9223372036854775807 - 1); @@ -14,7 +14,7 @@ define("MIN_32Bit", -2147483647 - 1); $longVals = array( MAX_64Bit, MIN_64Bit, MAX_32Bit, MIN_32Bit, MAX_64Bit - MAX_32Bit, MIN_64Bit - MIN_32Bit, - MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1, + MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1, MAX_64Bit -1, MAX_64Bit + 1, MIN_64Bit + 1, MIN_64Bit - 1 ); @@ -24,18 +24,18 @@ error_reporting(E_ERROR); foreach ($longVals as $longVal) { foreach($otherVals as $otherVal) { - echo "--- testing: $longVal ^ $otherVal ---\n"; + echo "--- testing: $longVal ^ $otherVal ---\n"; var_dump($longVal^$otherVal); } } foreach ($otherVals as $otherVal) { foreach($longVals as $longVal) { - echo "--- testing: $otherVal ^ $longVal ---\n"; + echo "--- testing: $otherVal ^ $longVal ---\n"; var_dump($otherVal^$longVal); } } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/bitwiseXor_variationStr.phpt b/tests/lang/operators/bitwiseXor_variationStr.phpt index 64d5eb75d8..dced933ee4 100644 --- a/tests/lang/operators/bitwiseXor_variationStr.phpt +++ b/tests/lang/operators/bitwiseXor_variationStr.phpt @@ -12,12 +12,12 @@ error_reporting(E_ERROR); foreach ($strVals as $strVal) { foreach($strVals as $otherVal) { - echo "--- testing: '$strVal' ^ '$otherVal' ---\n"; + echo "--- testing: '$strVal' ^ '$otherVal' ---\n"; var_dump(bin2hex($strVal^$otherVal)); } } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/divide_basiclong_64bit.phpt b/tests/lang/operators/divide_basiclong_64bit.phpt index 0dd08f534f..4349ae0025 100644 --- a/tests/lang/operators/divide_basiclong_64bit.phpt +++ b/tests/lang/operators/divide_basiclong_64bit.phpt @@ -6,7 +6,7 @@ if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only"); ?> --FILE-- <?php - + define("MAX_64Bit", 9223372036854775807); define("MAX_32Bit", 2147483647); define("MIN_64Bit", -9223372036854775807 - 1); @@ -14,7 +14,7 @@ define("MIN_32Bit", -2147483647 - 1); $longVals = array( MAX_64Bit, MIN_64Bit, MAX_32Bit, MIN_32Bit, MAX_64Bit - MAX_32Bit, MIN_64Bit - MIN_32Bit, - MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1, + MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1, MAX_64Bit -1, MAX_64Bit + 1, MIN_64Bit + 1, MIN_64Bit - 1 ); @@ -24,18 +24,18 @@ error_reporting(E_ERROR); foreach ($longVals as $longVal) { foreach($otherVals as $otherVal) { - echo "--- testing: $longVal / $otherVal ---\n"; + echo "--- testing: $longVal / $otherVal ---\n"; var_dump($longVal/$otherVal); } } foreach ($otherVals as $otherVal) { foreach($longVals as $longVal) { - echo "--- testing: $otherVal / $longVal ---\n"; + echo "--- testing: $otherVal / $longVal ---\n"; var_dump($otherVal/$longVal); } } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/divide_variationStr.phpt b/tests/lang/operators/divide_variationStr.phpt index 88ff8f1840..f908642765 100644 --- a/tests/lang/operators/divide_variationStr.phpt +++ b/tests/lang/operators/divide_variationStr.phpt @@ -12,12 +12,12 @@ error_reporting(E_ERROR); foreach ($strVals as $strVal) { foreach($strVals as $otherVal) { - echo "--- testing: '$strVal' / '$otherVal' ---\n"; + echo "--- testing: '$strVal' / '$otherVal' ---\n"; var_dump($strVal/$otherVal); } } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/modulus_basiclong_64bit.phpt b/tests/lang/operators/modulus_basiclong_64bit.phpt index 6806bd53a8..155649d203 100644 --- a/tests/lang/operators/modulus_basiclong_64bit.phpt +++ b/tests/lang/operators/modulus_basiclong_64bit.phpt @@ -6,7 +6,7 @@ if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only"); ?> --FILE-- <?php - + define("MAX_64Bit", 9223372036854775807); define("MAX_32Bit", 2147483647); define("MIN_64Bit", -9223372036854775807 - 1); @@ -14,7 +14,7 @@ define("MIN_32Bit", -2147483647 - 1); $longVals = array( MAX_64Bit, MIN_64Bit, MAX_32Bit, MIN_32Bit, MAX_64Bit - MAX_32Bit, MIN_64Bit - MIN_32Bit, - MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1, + MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1, MAX_64Bit -1, MAX_64Bit + 1, MIN_64Bit + 1, MIN_64Bit - 1 ); @@ -43,7 +43,7 @@ foreach ($otherVals as $otherVal) { } } } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/modulus_variationStr.phpt b/tests/lang/operators/modulus_variationStr.phpt index 6441428e3e..21765ecb7c 100644 --- a/tests/lang/operators/modulus_variationStr.phpt +++ b/tests/lang/operators/modulus_variationStr.phpt @@ -21,7 +21,7 @@ foreach ($strVals as $strVal) { } } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/multiply_basiclong_64bit.phpt b/tests/lang/operators/multiply_basiclong_64bit.phpt index 31d9188a77..512c3fbc18 100644 --- a/tests/lang/operators/multiply_basiclong_64bit.phpt +++ b/tests/lang/operators/multiply_basiclong_64bit.phpt @@ -6,7 +6,7 @@ if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only"); ?> --FILE-- <?php - + define("MAX_64Bit", 9223372036854775807); define("MAX_32Bit", 2147483647); define("MIN_64Bit", -9223372036854775807 - 1); @@ -14,7 +14,7 @@ define("MIN_32Bit", -2147483647 - 1); $longVals = array( MAX_64Bit, MIN_64Bit, MAX_32Bit, MIN_32Bit, MAX_64Bit - MAX_32Bit, MIN_64Bit - MIN_32Bit, - MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1, + MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1, MAX_64Bit -1, MAX_64Bit + 1, MIN_64Bit + 1, MIN_64Bit - 1 ); @@ -24,18 +24,18 @@ error_reporting(E_ERROR); foreach ($longVals as $longVal) { foreach($otherVals as $otherVal) { - echo "--- testing: $longVal * $otherVal ---\n"; + echo "--- testing: $longVal * $otherVal ---\n"; var_dump($longVal*$otherVal); } } foreach ($otherVals as $otherVal) { foreach($longVals as $longVal) { - echo "--- testing: $otherVal * $longVal ---\n"; + echo "--- testing: $otherVal * $longVal ---\n"; var_dump($otherVal*$longVal); } } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/multiply_variationStr.phpt b/tests/lang/operators/multiply_variationStr.phpt index 01d7e05074..50735e2548 100644 --- a/tests/lang/operators/multiply_variationStr.phpt +++ b/tests/lang/operators/multiply_variationStr.phpt @@ -12,12 +12,12 @@ error_reporting(E_ERROR); foreach ($strVals as $strVal) { foreach($strVals as $otherVal) { - echo "--- testing: '$strVal' * '$otherVal' ---\n"; + echo "--- testing: '$strVal' * '$otherVal' ---\n"; var_dump($strVal*$otherVal); } } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/negate_basiclong_64bit.phpt b/tests/lang/operators/negate_basiclong_64bit.phpt index 47b25e5397..bce8982126 100644 --- a/tests/lang/operators/negate_basiclong_64bit.phpt +++ b/tests/lang/operators/negate_basiclong_64bit.phpt @@ -6,7 +6,7 @@ if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only"); ?> --FILE-- <?php - + define("MAX_64Bit", 9223372036854775807); define("MAX_32Bit", 2147483647); define("MIN_64Bit", -9223372036854775807 - 1); @@ -14,7 +14,7 @@ define("MIN_32Bit", -2147483647 - 1); $longVals = array( MAX_64Bit, MIN_64Bit, MAX_32Bit, MIN_32Bit, MAX_64Bit - MAX_32Bit, MIN_64Bit - MIN_32Bit, - MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1, + MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1, MAX_64Bit -1, MAX_64Bit + 1, MIN_64Bit + 1, MIN_64Bit - 1 ); @@ -23,7 +23,7 @@ foreach ($longVals as $longVal) { echo "--- testing: $longVal ---\n"; var_dump(-$longVal); } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/negate_variationStr.phpt b/tests/lang/operators/negate_variationStr.phpt index ccff2fba2c..7956ef4a1c 100644 --- a/tests/lang/operators/negate_variationStr.phpt +++ b/tests/lang/operators/negate_variationStr.phpt @@ -13,7 +13,7 @@ foreach ($strVals as $strVal) { echo "--- testing: '$strVal' ---\n"; var_dump(-$strVal); } - + ?> ===DONE=== --EXPECTF-- diff --git a/tests/lang/operators/operator_equals_basic.phpt b/tests/lang/operators/operator_equals_basic.phpt index 9de4ed1a2a..1f83a48180 100644 --- a/tests/lang/operators/operator_equals_basic.phpt +++ b/tests/lang/operators/operator_equals_basic.phpt @@ -22,20 +22,20 @@ $invalid_float2 = array("- 67345.76567", "-67,345.76567", -67345.76566, -6.73457 $toCompare = array( - true, $valid_true, $valid_false, + true, $valid_true, $valid_false, false, $valid_false, $valid_true, $int1, $valid_int1, $invalid_int1, $int2, $valid_int2, $invalid_int2, $float1, $valid_float1, $invalid_float1, $float2, $valid_float2, $invalid_float2 ); - + $failed = false; for ($i = 0; $i < count($toCompare); $i +=3) { $typeToTest = $toCompare[$i]; $valid_compares = $toCompare[$i + 1]; $invalid_compares = $toCompare[$i + 2]; - + foreach($valid_compares as $compareVal) { if ($typeToTest == $compareVal) { // do nothing @@ -45,19 +45,19 @@ for ($i = 0; $i < count($toCompare); $i +=3) { $failed = true; } } - + foreach($invalid_compares as $compareVal) { if ($typeToTest == $compareVal) { echo "FAILED: '$typeToTest' == '$compareVal'\n"; $failed = true; } } - + } if ($failed == false) { echo "Test Passed\n"; } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/operator_equals_variation.phpt b/tests/lang/operators/operator_equals_variation.phpt index d72253404b..ad561454ae 100644 --- a/tests/lang/operators/operator_equals_variation.phpt +++ b/tests/lang/operators/operator_equals_variation.phpt @@ -6,7 +6,7 @@ if (PHP_INT_SIZE != 4) die("skip this test is for 32bit platform only"); ?> --FILE-- <?php - + define("MAX_64Bit", 9223372036854775807); define("MAX_32Bit", 2147483647); define("MIN_64Bit", -9223372036854775807 - 1); @@ -55,7 +55,7 @@ for ($i = 0; $i < count($invalidEqual); $i +=2) { if ($failed == false) { echo "Test Passed\n"; } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/operator_equals_variation_64bit.phpt b/tests/lang/operators/operator_equals_variation_64bit.phpt index ada6c2d7ec..15d440978e 100644 --- a/tests/lang/operators/operator_equals_variation_64bit.phpt +++ b/tests/lang/operators/operator_equals_variation_64bit.phpt @@ -6,7 +6,7 @@ if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only"); ?> --FILE-- <?php - + define("MAX_64Bit", 9223372036854775807); define("MAX_32Bit", 2147483647); define("MIN_64Bit", -9223372036854775807 - 1); @@ -57,7 +57,7 @@ for ($i = 0; $i < count($invalidEqual); $i +=2) { if ($failed == false) { echo "Test Passed\n"; } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/operator_gt_basic.phpt b/tests/lang/operators/operator_gt_basic.phpt index db856c62e6..66c457f0b1 100644 --- a/tests/lang/operators/operator_gt_basic.phpt +++ b/tests/lang/operators/operator_gt_basic.phpt @@ -24,19 +24,19 @@ $toCompare = array( // boolean test will result in both sides being converted to boolean so !0 = true and true is not > true for example // also note that a string of "0" is converted to false but a string of "0.0" is converted to true // false cannot be tested as 0 can never be > 0 or 1 - true, $valid_false, $valid_true, + true, $valid_false, $valid_true, $int1, $valid_int1, $invalid_int1, $int2, $valid_int2, $invalid_int2, $float1, $valid_float1, $invalid_float1, $float2, $valid_float2, $invalid_float2 ); - + $failed = false; for ($i = 0; $i < count($toCompare); $i +=3) { $typeToTest = $toCompare[$i]; $valid_compares = $toCompare[$i + 1]; $invalid_compares = $toCompare[$i + 2]; - + foreach($valid_compares as $compareVal) { if ($typeToTest > $compareVal) { // do nothing @@ -46,14 +46,14 @@ for ($i = 0; $i < count($toCompare); $i +=3) { $failed = true; } } - + foreach($invalid_compares as $compareVal) { if ($typeToTest > $compareVal) { echo "FAILED: '$typeToTest' > '$compareVal'\n"; $failed = true; } } - + } if ($failed == false) { echo "Test Passed\n"; diff --git a/tests/lang/operators/operator_gt_or_equal_basic.phpt b/tests/lang/operators/operator_gt_or_equal_basic.phpt index f1b1e01048..006c22baeb 100644 --- a/tests/lang/operators/operator_gt_or_equal_basic.phpt +++ b/tests/lang/operators/operator_gt_or_equal_basic.phpt @@ -22,19 +22,19 @@ $invalid_float2 = array(-67345.76564, -6.734576564E4); $toCompare = array( true, array_merge($valid_false, $valid_true), NULL, - false, $valid_false, $valid_true, + false, $valid_false, $valid_true, $int1, $valid_int1, $invalid_int1, $int2, $valid_int2, $invalid_int2, $float1, $valid_float1, $invalid_float1, $float2, $valid_float2, $invalid_float2 ); - + $failed = false; for ($i = 0; $i < count($toCompare); $i +=3) { $typeToTest = $toCompare[$i]; $valid_compares = $toCompare[$i + 1]; $invalid_compares = $toCompare[$i + 2]; - + foreach($valid_compares as $compareVal) { if ($typeToTest >= $compareVal) { // do nothing @@ -44,7 +44,7 @@ for ($i = 0; $i < count($toCompare); $i +=3) { $failed = true; } } - + if ($invalid_compares != NULL) { foreach($invalid_compares as $compareVal) { if ($typeToTest >= $compareVal) { @@ -53,7 +53,7 @@ for ($i = 0; $i < count($toCompare); $i +=3) { } } } - + } if ($failed == false) { echo "Test Passed\n"; diff --git a/tests/lang/operators/operator_gt_or_equal_variation.phpt b/tests/lang/operators/operator_gt_or_equal_variation.phpt index 2355ab4c45..1e3a338e73 100644 --- a/tests/lang/operators/operator_gt_or_equal_variation.phpt +++ b/tests/lang/operators/operator_gt_or_equal_variation.phpt @@ -6,7 +6,7 @@ if (PHP_INT_SIZE != 4) die("skip this test is for 32bit platform only"); ?> --FILE-- <?php - + define("MAX_64Bit", 9223372036854775807); define("MAX_32Bit", 2147483647); define("MIN_64Bit", -9223372036854775807 - 1); @@ -55,7 +55,7 @@ for ($i = 0; $i < count($invalidGtOrEqual); $i +=2) { if ($failed == false) { echo "Test Passed\n"; } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/operator_gt_or_equal_variation_64bit.phpt b/tests/lang/operators/operator_gt_or_equal_variation_64bit.phpt index 8a1ed35f10..d6245abbfc 100644 --- a/tests/lang/operators/operator_gt_or_equal_variation_64bit.phpt +++ b/tests/lang/operators/operator_gt_or_equal_variation_64bit.phpt @@ -6,7 +6,7 @@ if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only"); ?> --FILE-- <?php - + define("MAX_64Bit", 9223372036854775807); define("MAX_32Bit", 2147483647); define("MIN_64Bit", -9223372036854775807 - 1); @@ -55,7 +55,7 @@ for ($i = 0; $i < count($invalidGtOrEqual); $i +=2) { if ($failed == false) { echo "Test Passed\n"; } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/operator_gt_variation.phpt b/tests/lang/operators/operator_gt_variation.phpt index 937ebbbb63..4c56ec5e6a 100644 --- a/tests/lang/operators/operator_gt_variation.phpt +++ b/tests/lang/operators/operator_gt_variation.phpt @@ -2,7 +2,7 @@ Test > operator : max int 32bit range --FILE-- <?php - + define("MAX_64Bit", 9223372036854775807); define("MAX_32Bit", 2147483647); define("MIN_64Bit", -9223372036854775807 - 1); @@ -50,7 +50,7 @@ for ($i = 0; $i < count($invalidGreaterThan); $i +=2) { if ($failed == false) { echo "Test Passed\n"; } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/operator_gt_variation_64bit.phpt b/tests/lang/operators/operator_gt_variation_64bit.phpt index 15c6b88319..60a34c8986 100644 --- a/tests/lang/operators/operator_gt_variation_64bit.phpt +++ b/tests/lang/operators/operator_gt_variation_64bit.phpt @@ -6,7 +6,7 @@ if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only"); ?> --FILE-- <?php - + define("MAX_64Bit", 9223372036854775807); define("MAX_32Bit", 2147483647); define("MIN_64Bit", -9223372036854775807 - 1); @@ -54,7 +54,7 @@ for ($i = 0; $i < count($invalidGreaterThan); $i +=2) { if ($failed == false) { echo "Test Passed\n"; } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/operator_identical_basic.phpt b/tests/lang/operators/operator_identical_basic.phpt index e3a0fe272f..cddba995a6 100644 --- a/tests/lang/operators/operator_identical_basic.phpt +++ b/tests/lang/operators/operator_identical_basic.phpt @@ -15,27 +15,27 @@ $invalid_int2 = array("-67835", "-67835abc", " -67835", "-67835 ", -67835.000, $float1 = 57385.45835; $float2 = -67345.76567; -$valid_float1 = array(57385.45835, 5.738545835e4); +$valid_float1 = array(57385.45835, 5.738545835e4); $valid_float2 = array(-67345.76567, -6.734576567E4); $invalid_float1 = array("57385.45835", "57385.45835aaa", " 57385.45835", "57385. 45835", "57,385.45835", 57385.45834, 5.738545834e4); $invalid_float2 = array("-67345.76567", "-67345.76567aaa", " -67345.76567", "- 67345.76567", "-67,345.76567", -67345.76566, -6.734576566E4); $toCompare = array( - true, array(true), array_merge($valid_true, $valid_false), + true, array(true), array_merge($valid_true, $valid_false), false, array(false), array_merge($valid_true, $valid_false), $int1, $valid_int1, $invalid_int1, $int2, $valid_int2, $invalid_int2, $float1, $valid_float1, $invalid_float1, $float2, $valid_float2, $invalid_float2 ); - + $failed = false; for ($i = 0; $i < count($toCompare); $i +=3) { $typeToTest = $toCompare[$i]; $valid_compares = $toCompare[$i + 1]; $invalid_compares = $toCompare[$i + 2]; - + foreach($valid_compares as $compareVal) { if ($typeToTest === $compareVal) { // do nothing @@ -45,19 +45,19 @@ for ($i = 0; $i < count($toCompare); $i +=3) { $failed = true; } } - + foreach($invalid_compares as $compareVal) { if ($typeToTest === $compareVal) { echo "FAILED: '$typeToTest' == '$compareVal'\n"; $failed = true; } } - + } if ($failed == false) { echo "Test Passed\n"; } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/operator_identical_variation.phpt b/tests/lang/operators/operator_identical_variation.phpt index a215fef0a4..8b8e1dc7ea 100644 --- a/tests/lang/operators/operator_identical_variation.phpt +++ b/tests/lang/operators/operator_identical_variation.phpt @@ -6,7 +6,7 @@ if (PHP_INT_SIZE != 4) die("skip this test is for 32bit platform only"); ?> --FILE-- <?php - + define("MAX_64Bit", 9223372036854775807); define("MAX_32Bit", 2147483647); define("MIN_64Bit", -9223372036854775807 - 1); @@ -55,7 +55,7 @@ for ($i = 0; $i < count($invalidIdentical); $i +=2) { if ($failed == false) { echo "Test Passed\n"; } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/operator_identical_variation_64bit.phpt b/tests/lang/operators/operator_identical_variation_64bit.phpt index 0c8d398daf..cd098699f2 100644 --- a/tests/lang/operators/operator_identical_variation_64bit.phpt +++ b/tests/lang/operators/operator_identical_variation_64bit.phpt @@ -6,7 +6,7 @@ if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only"); ?> --FILE-- <?php - + define("MAX_64Bit", 9223372036854775807); define("MAX_32Bit", 2147483647); define("MIN_64Bit", -9223372036854775807 - 1); @@ -57,7 +57,7 @@ for ($i = 0; $i < count($invalidIdentical); $i +=2) { if ($failed == false) { echo "Test Passed\n"; } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/operator_lt_basic.phpt b/tests/lang/operators/operator_lt_basic.phpt index 41f18ef9d2..4574fb7d1d 100644 --- a/tests/lang/operators/operator_lt_basic.phpt +++ b/tests/lang/operators/operator_lt_basic.phpt @@ -21,19 +21,19 @@ $invalid_float2 = array(-67345.76567, -6.734576567E4); $toCompare = array( - false, $valid_true, $valid_false, + false, $valid_true, $valid_false, $int1, $valid_int1, $invalid_int1, $int2, $valid_int2, $invalid_int2, $float1, $valid_float1, $invalid_float1, $float2, $valid_float2, $invalid_float2 ); - + $failed = false; for ($i = 0; $i < count($toCompare); $i +=3) { $typeToTest = $toCompare[$i]; $valid_compares = $toCompare[$i + 1]; $invalid_compares = $toCompare[$i + 2]; - + foreach($valid_compares as $compareVal) { if ($typeToTest < $compareVal) { // do nothing @@ -43,14 +43,14 @@ for ($i = 0; $i < count($toCompare); $i +=3) { $failed = true; } } - + foreach($invalid_compares as $compareVal) { if ($typeToTest < $compareVal) { echo "FAILED: '$typeToTest' < '$compareVal'\n"; $failed = true; } } - + } if ($failed == false) { echo "Test Passed\n"; diff --git a/tests/lang/operators/operator_lt_or_equal_basic.phpt b/tests/lang/operators/operator_lt_or_equal_basic.phpt index 85a86e1996..5439fd7d75 100644 --- a/tests/lang/operators/operator_lt_or_equal_basic.phpt +++ b/tests/lang/operators/operator_lt_or_equal_basic.phpt @@ -21,19 +21,19 @@ $invalid_float2 = array(-67345.76569, -6.734576569E4); $toCompare = array( true, $valid_true, $valid_false, - false, array_merge($valid_false, $valid_true), NULL, + false, array_merge($valid_false, $valid_true), NULL, $int1, $valid_int1, $invalid_int1, $int2, $valid_int2, $invalid_int2, $float1, $valid_float1, $invalid_float1, $float2, $valid_float2, $invalid_float2 ); - + $failed = false; for ($i = 0; $i < count($toCompare); $i +=3) { $typeToTest = $toCompare[$i]; $valid_compares = $toCompare[$i + 1]; $invalid_compares = $toCompare[$i + 2]; - + foreach($valid_compares as $compareVal) { if ($typeToTest <= $compareVal) { // do nothing @@ -43,7 +43,7 @@ for ($i = 0; $i < count($toCompare); $i +=3) { $failed = true; } } - + if ($invalid_compares != NULL) { foreach($invalid_compares as $compareVal) { if ($typeToTest <= $compareVal) { @@ -52,7 +52,7 @@ for ($i = 0; $i < count($toCompare); $i +=3) { } } } - + } if ($failed == false) { echo "Test Passed\n"; diff --git a/tests/lang/operators/operator_lt_or_equal_variation.phpt b/tests/lang/operators/operator_lt_or_equal_variation.phpt index 5724511a0e..a003138ceb 100644 --- a/tests/lang/operators/operator_lt_or_equal_variation.phpt +++ b/tests/lang/operators/operator_lt_or_equal_variation.phpt @@ -6,7 +6,7 @@ if (PHP_INT_SIZE != 4) die("skip this test is for 32bit platform only"); ?> --FILE-- <?php - + define("MAX_64Bit", 9223372036854775807); define("MAX_32Bit", 2147483647); define("MIN_64Bit", -9223372036854775807 - 1); @@ -55,7 +55,7 @@ for ($i = 0; $i < count($invalidLtOrEqual); $i +=2) { if ($failed == false) { echo "Test Passed\n"; } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/operator_lt_or_equal_variation_64bit.phpt b/tests/lang/operators/operator_lt_or_equal_variation_64bit.phpt index f3b16c1fc9..50afd9b3e5 100644 --- a/tests/lang/operators/operator_lt_or_equal_variation_64bit.phpt +++ b/tests/lang/operators/operator_lt_or_equal_variation_64bit.phpt @@ -6,7 +6,7 @@ if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only"); ?> --FILE-- <?php - + define("MAX_64Bit", 9223372036854775807); define("MAX_32Bit", 2147483647); define("MIN_64Bit", -9223372036854775807 - 1); @@ -55,7 +55,7 @@ for ($i = 0; $i < count($invalidLtOrEqual); $i +=2) { if ($failed == false) { echo "Test Passed\n"; } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/operator_lt_variation.phpt b/tests/lang/operators/operator_lt_variation.phpt index f210fe4657..18a6631665 100644 --- a/tests/lang/operators/operator_lt_variation.phpt +++ b/tests/lang/operators/operator_lt_variation.phpt @@ -2,7 +2,7 @@ Test < operator : max int 32bit range --FILE-- <?php - + define("MAX_64Bit", 9223372036854775807); define("MAX_32Bit", 2147483647); define("MIN_64Bit", -9223372036854775807 - 1); @@ -48,7 +48,7 @@ for ($i = 0; $i < count($invalidLessThan); $i +=2) { if ($failed == false) { echo "Test Passed\n"; } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/operator_lt_variation_64bit.phpt b/tests/lang/operators/operator_lt_variation_64bit.phpt index 3ee274aea0..663b840e61 100644 --- a/tests/lang/operators/operator_lt_variation_64bit.phpt +++ b/tests/lang/operators/operator_lt_variation_64bit.phpt @@ -6,7 +6,7 @@ if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only"); ?> --FILE-- <?php - + define("MAX_64Bit", 9223372036854775807); define("MAX_32Bit", 2147483647); define("MIN_64Bit", -9223372036854775807 - 1); @@ -52,7 +52,7 @@ for ($i = 0; $i < count($invalidLessThan); $i +=2) { if ($failed == false) { echo "Test Passed\n"; } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/operator_notequals_basic.phpt b/tests/lang/operators/operator_notequals_basic.phpt index cef0be6279..35bd83e445 100644 --- a/tests/lang/operators/operator_notequals_basic.phpt +++ b/tests/lang/operators/operator_notequals_basic.phpt @@ -22,20 +22,20 @@ $invalid_float2 = array("-67345.76567", "-67345.76567aaa", " -67345.76567", -6. $toCompare = array( - true, $valid_false, $valid_true, + true, $valid_false, $valid_true, false, $valid_true, $valid_false, $int1, $valid_int1, $invalid_int1, $int2, $valid_int2, $invalid_int2, $float1, $valid_float1, $invalid_float1, $float2, $valid_float2, $invalid_float2 ); - + $failed = false; for ($i = 0; $i < count($toCompare); $i +=3) { $typeToTest = $toCompare[$i]; $valid_compares = $toCompare[$i + 1]; $invalid_compares = $toCompare[$i + 2]; - + foreach($valid_compares as $compareVal) { if ($typeToTest != $compareVal && $typeToTest <> $compareVal) { // do nothing @@ -45,19 +45,19 @@ for ($i = 0; $i < count($toCompare); $i +=3) { $failed = true; } } - + foreach($invalid_compares as $compareVal) { if ($typeToTest != $compareVal || $typeToTest <> $compareVal) { echo "FAILED: '$typeToTest' != '$compareVal'\n"; $failed = true; } } - + } if ($failed == false) { echo "Test Passed\n"; } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/operator_notequals_variation.phpt b/tests/lang/operators/operator_notequals_variation.phpt index 25bbfc5859..137888506f 100644 --- a/tests/lang/operators/operator_notequals_variation.phpt +++ b/tests/lang/operators/operator_notequals_variation.phpt @@ -6,7 +6,7 @@ if (PHP_INT_SIZE != 4) die("skip this test is for 32bit platform only"); ?> --FILE-- <?php - + define("MAX_64Bit", 9223372036854775807); define("MAX_32Bit", 2147483647); define("MIN_64Bit", -9223372036854775807 - 1); @@ -37,7 +37,7 @@ for ($i = 0; $i < count($validNotEquals); $i +=2) { else { echo "FAILED: '$typeToTestVal' == '$compareVal'\n"; $failed = true; - } + } } } // test invalid values @@ -55,7 +55,7 @@ for ($i = 0; $i < count($invalidNotEquals); $i +=2) { if ($failed == false) { echo "Test Passed\n"; } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/operator_notequals_variation_64bit.phpt b/tests/lang/operators/operator_notequals_variation_64bit.phpt index 6fbc496fa5..ea06b49264 100644 --- a/tests/lang/operators/operator_notequals_variation_64bit.phpt +++ b/tests/lang/operators/operator_notequals_variation_64bit.phpt @@ -6,7 +6,7 @@ if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only"); ?> --FILE-- <?php - + define("MAX_64Bit", 9223372036854775807); define("MAX_32Bit", 2147483647); define("MIN_64Bit", -9223372036854775807 - 1); @@ -57,7 +57,7 @@ for ($i = 0; $i < count($invalidNotEquals); $i +=2) { if ($failed == false) { echo "Test Passed\n"; } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/operator_notidentical_basic.phpt b/tests/lang/operators/operator_notidentical_basic.phpt index 9f21ea4bca..d24c936119 100644 --- a/tests/lang/operators/operator_notidentical_basic.phpt +++ b/tests/lang/operators/operator_notidentical_basic.phpt @@ -17,25 +17,25 @@ $float1 = 57385.45835; $float2 = -67345.76567; $valid_float1 = array("57385.45835", "57385.45835aaa", " 57385.45835", "57385. 45835", "57,385.45835", 57385.45834, 5.738545834e4); $valid_float2 = array("-67345.76567", "-67345.76567aaa", " -67345.76567", "- 67345.76567", "-67,345.76567", -67345.76566, -6.734576566E4); -$invalid_float1 = array(57385.45835, 5.738545835e4); +$invalid_float1 = array(57385.45835, 5.738545835e4); $invalid_float2 = array(-67345.76567, -6.734576567E4); $toCompare = array( - true, array_merge($valid_true, $valid_false), array(true), + true, array_merge($valid_true, $valid_false), array(true), false, array_merge($valid_true, $valid_false), array(false), $int1, $valid_int1, $invalid_int1, $int2, $valid_int2, $invalid_int2, $float1, $valid_float1, $invalid_float1, $float2, $valid_float2, $invalid_float2 ); - + $failed = false; for ($i = 0; $i < count($toCompare); $i +=3) { $typeToTest = $toCompare[$i]; $valid_compares = $toCompare[$i + 1]; $invalid_compares = $toCompare[$i + 2]; - + foreach($valid_compares as $compareVal) { if ($typeToTest !== $compareVal) { // do nothing @@ -45,19 +45,19 @@ for ($i = 0; $i < count($toCompare); $i +=3) { $failed = true; } } - + foreach($invalid_compares as $compareVal) { if ($typeToTest !== $compareVal) { echo "FAILED: '$typeToTest' !== '$compareVal'\n"; $failed = true; } } - + } if ($failed == false) { echo "Test Passed\n"; } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/operator_notidentical_variation.phpt b/tests/lang/operators/operator_notidentical_variation.phpt index a9fbcf60e1..bae03f85b7 100644 --- a/tests/lang/operators/operator_notidentical_variation.phpt +++ b/tests/lang/operators/operator_notidentical_variation.phpt @@ -6,7 +6,7 @@ if (PHP_INT_SIZE != 4) die("skip this test is for 32bit platform only"); ?> --FILE-- <?php - + define("MAX_64Bit", 9223372036854775807); define("MAX_32Bit", 2147483647); define("MIN_64Bit", -9223372036854775807 - 1); @@ -36,7 +36,7 @@ for ($i = 0; $i < count($validNotIdentical); $i +=2) { } else { echo "FAILED: '$typeToTestVal' === '$compareVal'\n"; - $failed = true; + $failed = true; } } } @@ -56,7 +56,7 @@ for ($i = 0; $i < count($invalidNotIdentical); $i +=2) { if ($failed == false) { echo "Test Passed\n"; } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/operator_notidentical_variation_64bit.phpt b/tests/lang/operators/operator_notidentical_variation_64bit.phpt index aa5aab7a59..d24f8b6234 100644 --- a/tests/lang/operators/operator_notidentical_variation_64bit.phpt +++ b/tests/lang/operators/operator_notidentical_variation_64bit.phpt @@ -6,7 +6,7 @@ if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only"); ?> --FILE-- <?php - + define("MAX_64Bit", 9223372036854775807); define("MAX_32Bit", 2147483647); define("MIN_64Bit", -9223372036854775807 - 1); @@ -57,7 +57,7 @@ for ($i = 0; $i < count($invalidNotIdentical); $i +=2) { if ($failed == false) { echo "Test Passed\n"; } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/operator_spaceship_basic.phpt b/tests/lang/operators/operator_spaceship_basic.phpt index 81b0516757..13b80612dc 100644 --- a/tests/lang/operators/operator_spaceship_basic.phpt +++ b/tests/lang/operators/operator_spaceship_basic.phpt @@ -24,19 +24,19 @@ $toCompare = array( // boolean test will result in both sides being converted to boolean so !0 = true and true is not > true for example // also note that a string of "0" is converted to false but a string of "0.0" is converted to true // false cannot be tested as 0 can never be > 0 or 1 - true, $valid_false, $valid_true, + true, $valid_false, $valid_true, $int1, $valid_int1, $invalid_int1, $int2, $valid_int2, $invalid_int2, $float1, $valid_float1, $invalid_float1, $float2, $valid_float2, $invalid_float2 ); - + $failed = false; for ($i = 0; $i < count($toCompare); $i +=3) { $typeToTest = $toCompare[$i]; $valid_compares = $toCompare[$i + 1]; $invalid_compares = $toCompare[$i + 2]; - + foreach($valid_compares as $compareVal) { if (($typeToTest <=> $compareVal) === 1) { // do nothing @@ -60,7 +60,7 @@ for ($i = 0; $i < count($toCompare); $i +=3) { $failed = true; } } - + foreach($invalid_compares as $compareVal) { if (($typeToTest <=> $compareVal) === 1) { echo "FAILED: ('$typeToTest' <=> '$compareVal') === 1\n"; @@ -75,7 +75,7 @@ for ($i = 0; $i < count($toCompare); $i +=3) { $failed = true; } } - + if (($typeToTest <=> $typeToTest) === 0) { // do nothing } diff --git a/tests/lang/operators/postdec_basiclong_64bit.phpt b/tests/lang/operators/postdec_basiclong_64bit.phpt index f3e825ca3d..5d0af4d553 100644 --- a/tests/lang/operators/postdec_basiclong_64bit.phpt +++ b/tests/lang/operators/postdec_basiclong_64bit.phpt @@ -6,7 +6,7 @@ if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only"); ?> --FILE-- <?php - + define("MAX_64Bit", 9223372036854775807); define("MAX_32Bit", 2147483647); define("MIN_64Bit", -9223372036854775807 - 1); @@ -14,7 +14,7 @@ define("MIN_32Bit", -2147483647 - 1); $longVals = array( MAX_64Bit, MIN_64Bit, MAX_32Bit, MIN_32Bit, MAX_64Bit - MAX_32Bit, MIN_64Bit - MIN_32Bit, - MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1, + MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1, MAX_64Bit -1, MAX_64Bit + 1, MIN_64Bit + 1, MIN_64Bit - 1 ); @@ -24,7 +24,7 @@ foreach ($longVals as $longVal) { $longVal--; var_dump($longVal); } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/postdec_variationStr.phpt b/tests/lang/operators/postdec_variationStr.phpt index 0db326d27e..da88951e46 100644 --- a/tests/lang/operators/postdec_variationStr.phpt +++ b/tests/lang/operators/postdec_variationStr.phpt @@ -14,7 +14,7 @@ foreach ($strVals as $strVal) { $strVal--; var_dump($strVal); } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/postinc_basiclong_64bit.phpt b/tests/lang/operators/postinc_basiclong_64bit.phpt index 18e8bddedd..d1003e22a5 100644 --- a/tests/lang/operators/postinc_basiclong_64bit.phpt +++ b/tests/lang/operators/postinc_basiclong_64bit.phpt @@ -6,7 +6,7 @@ if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only"); ?> --FILE-- <?php - + define("MAX_64Bit", 9223372036854775807); define("MAX_32Bit", 2147483647); define("MIN_64Bit", -9223372036854775807 - 1); @@ -14,7 +14,7 @@ define("MIN_32Bit", -2147483647 - 1); $longVals = array( MAX_64Bit, MIN_64Bit, MAX_32Bit, MIN_32Bit, MAX_64Bit - MAX_32Bit, MIN_64Bit - MIN_32Bit, - MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1, + MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1, MAX_64Bit -1, MAX_64Bit + 1, MIN_64Bit + 1, MIN_64Bit - 1 ); @@ -24,7 +24,7 @@ foreach ($longVals as $longVal) { $longVal++; var_dump($longVal); } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/postinc_variationStr.phpt b/tests/lang/operators/postinc_variationStr.phpt index 35e19888e1..c83d598fb7 100644 --- a/tests/lang/operators/postinc_variationStr.phpt +++ b/tests/lang/operators/postinc_variationStr.phpt @@ -14,7 +14,7 @@ foreach ($strVals as $strVal) { $strVal++; var_dump($strVal); } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/predec_basiclong_64bit.phpt b/tests/lang/operators/predec_basiclong_64bit.phpt index b2b11709b3..1f460a06e0 100644 --- a/tests/lang/operators/predec_basiclong_64bit.phpt +++ b/tests/lang/operators/predec_basiclong_64bit.phpt @@ -6,7 +6,7 @@ if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only"); ?> --FILE-- <?php - + define("MAX_64Bit", 9223372036854775807); define("MAX_32Bit", 2147483647); define("MIN_64Bit", -9223372036854775807 - 1); @@ -14,7 +14,7 @@ define("MIN_32Bit", -2147483647 - 1); $longVals = array( MAX_64Bit, MIN_64Bit, MAX_32Bit, MIN_32Bit, MAX_64Bit - MAX_32Bit, MIN_64Bit - MIN_32Bit, - MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1, + MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1, MAX_64Bit -1, MAX_64Bit + 1, MIN_64Bit + 1, MIN_64Bit - 1 ); @@ -23,7 +23,7 @@ foreach ($longVals as $longVal) { echo "--- testing: $longVal ---\n"; var_dump(--$longVal); } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/predec_variationStr.phpt b/tests/lang/operators/predec_variationStr.phpt index 1d1fade74d..8fb1bffac8 100644 --- a/tests/lang/operators/predec_variationStr.phpt +++ b/tests/lang/operators/predec_variationStr.phpt @@ -13,7 +13,7 @@ foreach ($strVals as $strVal) { echo "--- testing: '$strVal' ---\n"; var_dump(--$strVal); } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/preinc_basiclong_64bit.phpt b/tests/lang/operators/preinc_basiclong_64bit.phpt index e24cc283aa..40a03f9d7a 100644 --- a/tests/lang/operators/preinc_basiclong_64bit.phpt +++ b/tests/lang/operators/preinc_basiclong_64bit.phpt @@ -6,7 +6,7 @@ if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only"); ?> --FILE-- <?php - + define("MAX_64Bit", 9223372036854775807); define("MAX_32Bit", 2147483647); define("MIN_64Bit", -9223372036854775807 - 1); @@ -14,7 +14,7 @@ define("MIN_32Bit", -2147483647 - 1); $longVals = array( MAX_64Bit, MIN_64Bit, MAX_32Bit, MIN_32Bit, MAX_64Bit - MAX_32Bit, MIN_64Bit - MIN_32Bit, - MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1, + MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1, MAX_64Bit -1, MAX_64Bit + 1, MIN_64Bit + 1, MIN_64Bit - 1 ); @@ -23,7 +23,7 @@ foreach ($longVals as $longVal) { echo "--- testing: $longVal ---\n"; var_dump(++$longVal); } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/subtract_basiclong_64bit.phpt b/tests/lang/operators/subtract_basiclong_64bit.phpt index ca80e3f52d..0c403f343e 100644 --- a/tests/lang/operators/subtract_basiclong_64bit.phpt +++ b/tests/lang/operators/subtract_basiclong_64bit.phpt @@ -6,7 +6,7 @@ if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only"); ?> --FILE-- <?php - + define("MAX_64Bit", 9223372036854775807); define("MAX_32Bit", 2147483647); define("MIN_64Bit", -9223372036854775807 - 1); @@ -14,7 +14,7 @@ define("MIN_32Bit", -2147483647 - 1); $longVals = array( MAX_64Bit, MIN_64Bit, MAX_32Bit, MIN_32Bit, MAX_64Bit - MAX_32Bit, MIN_64Bit - MIN_32Bit, - MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1, + MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1, MAX_64Bit -1, MAX_64Bit + 1, MIN_64Bit + 1, MIN_64Bit - 1 ); @@ -24,18 +24,18 @@ error_reporting(E_ERROR); foreach ($longVals as $longVal) { foreach($otherVals as $otherVal) { - echo "--- testing: $longVal - $otherVal ---\n"; + echo "--- testing: $longVal - $otherVal ---\n"; var_dump($longVal-$otherVal); } } foreach ($otherVals as $otherVal) { foreach($longVals as $longVal) { - echo "--- testing: $otherVal - $longVal ---\n"; + echo "--- testing: $otherVal - $longVal ---\n"; var_dump($otherVal-$longVal); } } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/operators/subtract_variationStr.phpt b/tests/lang/operators/subtract_variationStr.phpt index 51b5ed4dca..393b172fb1 100644 --- a/tests/lang/operators/subtract_variationStr.phpt +++ b/tests/lang/operators/subtract_variationStr.phpt @@ -12,12 +12,12 @@ error_reporting(E_ERROR); foreach ($strVals as $strVal) { foreach($strVals as $otherVal) { - echo "--- testing: '$strVal' - '$otherVal' ---\n"; + echo "--- testing: '$strVal' - '$otherVal' ---\n"; var_dump($strVal-$otherVal); } } - + ?> ===DONE=== --EXPECT-- diff --git a/tests/lang/passByReference_003.phpt b/tests/lang/passByReference_003.phpt index bbbc564654..8fe27407f1 100644 --- a/tests/lang/passByReference_003.phpt +++ b/tests/lang/passByReference_003.phpt @@ -1,5 +1,5 @@ --TEST-- -Implicit initialisation when passing by reference +Implicit initialisation when passing by reference --FILE-- <?php function passbyVal($val) { diff --git a/tests/lang/passByReference_005.phpt b/tests/lang/passByReference_005.phpt index d637467681..e3b0e21c5c 100644 --- a/tests/lang/passByReference_005.phpt +++ b/tests/lang/passByReference_005.phpt @@ -43,32 +43,32 @@ class C { function v($val) { $val = "Val changed"; } - + function r(&$ref) { $ref = "Ref changed"; } - + function vv($val1, $val2) { $val1 = "Val1 changed"; $val2 = "Val2 changed"; } - + function vr($val, &$ref) { $val = "Val changed"; $ref = "Ref changed"; } - + function rv(&$ref, $val) { $val = "Val changed"; $ref = "Ref changed"; } - + function rr(&$ref1, &$ref2) { $ref1 = "Ref1 changed"; $ref2 = "Ref2 changed"; } -} +} echo "\n ---- Pass by ref / pass by val: functions ----\n"; unset($u1, $u2); diff --git a/tests/lang/passByReference_006.phpt b/tests/lang/passByReference_006.phpt index d3857cac40..f725092618 100644 --- a/tests/lang/passByReference_006.phpt +++ b/tests/lang/passByReference_006.phpt @@ -30,7 +30,7 @@ class C { $ref5 = "Ref5 changed"; } -} +} echo "\n ---- Pass uninitialised array & object by ref: function call ---\n"; unset($u1, $u2, $u3, $u4, $u5); diff --git a/tests/lang/passByReference_007.phpt b/tests/lang/passByReference_007.phpt index 300ce56d7c..51594da0f3 100644 --- a/tests/lang/passByReference_007.phpt +++ b/tests/lang/passByReference_007.phpt @@ -7,7 +7,7 @@ class C { global $a; return $a; } - + static function &sreturnReference() { global $a; return $a; @@ -17,7 +17,7 @@ class C { global $a; return $a; } - + function &returnReference() { global $a; return $a; diff --git a/tests/lang/passByReference_008.phpt b/tests/lang/passByReference_008.phpt index c7623fb73a..4fd9a819a8 100644 --- a/tests/lang/passByReference_008.phpt +++ b/tests/lang/passByReference_008.phpt @@ -1,5 +1,5 @@ --TEST-- -Pass same variable by ref and by value. +Pass same variable by ref and by value. --FILE-- <?php function valRef($x, &$y) { diff --git a/tests/lang/passByReference_009.phpt b/tests/lang/passByReference_009.phpt index b1b0c358ee..7b723d552e 100644 --- a/tests/lang/passByReference_009.phpt +++ b/tests/lang/passByReference_009.phpt @@ -5,7 +5,7 @@ Assignement as argument function foo(&$x, &$y) { $x = 1; echo $y ; } $x = 0; - foo($x, $x); // prints 1 .. + foo($x, $x); // prints 1 .. function foo2($x, &$y, $z) diff --git a/tests/lang/passByReference_010.phpt b/tests/lang/passByReference_010.phpt index c2e4ba1eaf..431659a24a 100644 --- a/tests/lang/passByReference_010.phpt +++ b/tests/lang/passByReference_010.phpt @@ -6,30 +6,30 @@ Passing assignments by reference function f(&$a) { var_dump($a); $a = "a.changed"; -} +} echo "\n\n---> Pass constant assignment by reference:\n"; f($a="a.original"); -var_dump($a); +var_dump($a); echo "\n\n---> Pass variable assignment by reference:\n"; unset($a); $a = "a.original"; f($b = $a); -var_dump($a); +var_dump($a); echo "\n\n---> Pass reference assignment by reference:\n"; unset($a, $b); $a = "a.original"; f($b =& $a); -var_dump($a); +var_dump($a); echo "\n\n---> Pass concat assignment by reference:\n"; unset($a, $b); $b = "b.original"; $a = "a.original"; f($b .= $a); -var_dump($a); +var_dump($a); ?> --EXPECTF-- diff --git a/tests/lang/passByReference_012.phpt b/tests/lang/passByReference_012.phpt index 69d53ca261..3bc60a484e 100644 --- a/tests/lang/passByReference_012.phpt +++ b/tests/lang/passByReference_012.phpt @@ -8,7 +8,7 @@ Test pass by reference semantics $stack = array ( array ( 'two' )); var_dump(array_shift(array_shift($stack))); -// This should show the identical warning +// This should show the identical warning $original = array ( array ( 'one' )); $stack = $original; var_dump(array_shift(array_shift($stack))); diff --git a/tests/lang/returnByReference.002.phpt b/tests/lang/returnByReference.002.phpt index 99365f1b14..0880a8b7a5 100644 --- a/tests/lang/returnByReference.002.phpt +++ b/tests/lang/returnByReference.002.phpt @@ -15,12 +15,12 @@ function returnVal() { $a = "original"; $b =& returnVal(); $b = "changed"; -var_dump($a); //expecting warning + "original" +var_dump($a); //expecting warning + "original" $a = "original"; $b =& returnRef(); $b = "changed"; -var_dump($a); //expecting "changed" +var_dump($a); //expecting "changed" ?> --EXPECTF-- diff --git a/tests/lang/returnByReference.004.phpt b/tests/lang/returnByReference.004.phpt index b37506ce0a..1b01bafae6 100644 --- a/tests/lang/returnByReference.004.phpt +++ b/tests/lang/returnByReference.004.phpt @@ -10,7 +10,7 @@ Class C { static function &returnConstantByRef() { return 100; } - + static function &returnVariableByRef() { return $GLOBALS['a']; } diff --git a/tests/lang/returnByReference.005.phpt b/tests/lang/returnByReference.005.phpt index adb11617c4..d446553973 100644 --- a/tests/lang/returnByReference.005.phpt +++ b/tests/lang/returnByReference.005.phpt @@ -6,11 +6,11 @@ Class C { function returnConstantByValue() { return 100; } - + function &returnConstantByRef() { return 100; } - + static function &returnVariableByRef() { return $GLOBALS['a']; } diff --git a/tests/lang/returnByReference.007.phpt b/tests/lang/returnByReference.007.phpt index e2ae4e6cd3..4879c16f93 100644 --- a/tests/lang/returnByReference.007.phpt +++ b/tests/lang/returnByReference.007.phpt @@ -6,15 +6,15 @@ class C { static function returnConstantByValue() { return 100; } - + static function &returnConstantByRef() { return 100; } - + static function &returnVariableByRef() { return $GLOBALS['a']; } - + static function &returnFunctionCallByRef($functionToCall) { return C::$functionToCall(); } diff --git a/tests/lang/returnByReference.008.phpt b/tests/lang/returnByReference.008.phpt index 6492342cb5..b39832b5d8 100644 --- a/tests/lang/returnByReference.008.phpt +++ b/tests/lang/returnByReference.008.phpt @@ -6,15 +6,15 @@ class C { function returnConstantByValue() { return 100; } - + function &returnConstantByRef() { return 100; } - + function &returnVariableByRef() { return $GLOBALS['a']; } - + function &returnFunctionCallByRef($functionToCall) { return $this->$functionToCall(); } diff --git a/tests/lang/returnByReference.009.phpt b/tests/lang/returnByReference.009.phpt index 9e7470edbc..0d51a22158 100644 --- a/tests/lang/returnByReference.009.phpt +++ b/tests/lang/returnByReference.009.phpt @@ -6,7 +6,7 @@ Returning a references returned by another function function &returnVarByRef () { $b=1; - return $b; + return $b; } function &testReturnVarByRef() { @@ -14,7 +14,7 @@ function &testReturnVarByRef() { } function returnVal () { -return 1; +return 1; } function &testReturnValByRef() { diff --git a/tests/lang/static_basic_001.phpt b/tests/lang/static_basic_001.phpt index e7a9ff163f..47da74d8ce 100644 --- a/tests/lang/static_basic_001.phpt +++ b/tests/lang/static_basic_001.phpt @@ -5,12 +5,12 @@ Static keyword - basic tests echo "\nSame variable used as static and non static.\n"; function staticNonStatic() { - echo "---------\n"; + echo "---------\n"; $a=0; - echo "$a\n"; + echo "$a\n"; static $a=10; echo "$a\n"; - $a++; + $a++; } staticNonStatic(); staticNonStatic(); diff --git a/tests/lang/static_basic_002.phpt b/tests/lang/static_basic_002.phpt index 06e2f724ec..7e4e0bc3f4 100644 --- a/tests/lang/static_basic_002.phpt +++ b/tests/lang/static_basic_002.phpt @@ -15,7 +15,7 @@ var_dump($a); function foo() { static $a = 13; static $a = 14; - + var_dump($a); } diff --git a/tests/lang/static_variation_001.phpt b/tests/lang/static_variation_001.phpt index 3c540368ed..d8ebfd2ea1 100644 --- a/tests/lang/static_variation_001.phpt +++ b/tests/lang/static_variation_001.phpt @@ -12,9 +12,9 @@ function f1() { static $a = array(4,5,6); var_dump($a); } - + var_dump($a); - + } f1(); @@ -25,12 +25,12 @@ eval(' static $b = array(10,11,12); '); function f2() { eval(' static $b = array(1,2,3); '); - + function g2a() { eval(' static $b = array(4,5,6); '); - var_dump($b); + var_dump($b); } - + eval('function g2b() { static $b = array(7, 8, 9); var_dump($b); } '); var_dump($b); } diff --git a/tests/lang/static_variation_002.phpt b/tests/lang/static_variation_002.phpt index 2be680822e..abb359c1d4 100644 --- a/tests/lang/static_variation_002.phpt +++ b/tests/lang/static_variation_002.phpt @@ -7,7 +7,7 @@ Class C { function f() { static $a = array(1,2,3); eval(' static $k = array(4,5,6); '); - + function cfg() { static $a = array(7,8,9); eval(' static $k = array(10,11,12); '); diff --git a/tests/lang/this_assignment.phpt b/tests/lang/this_assignment.phpt index 14644d69a9..a7c76174a5 100644 --- a/tests/lang/this_assignment.phpt +++ b/tests/lang/this_assignment.phpt @@ -6,7 +6,7 @@ class first { function me() { echo "first"; } - function who() { + function who() { global $a,$b; $this->me(); $a->me(); @@ -20,7 +20,7 @@ class first { class second { - function who() { + function who() { global $a,$b; $this->me(); $a->me(); diff --git a/tests/output/bug60321.phpt b/tests/output/bug60321.phpt index 9802a57ccd..e9c109dbf7 100644 --- a/tests/output/bug60321.phpt +++ b/tests/output/bug60321.phpt @@ -2,7 +2,7 @@ Bug #60321 (ob_get_status(true) no longer returns an array when buffer is empty) --FILE-- <?php -$return = ob_get_status(true); +$return = ob_get_status(true); var_dump($return); --EXPECT-- array(0) { diff --git a/tests/output/bug65593.phpt b/tests/output/bug65593.phpt index 3375a6bf08..2e40afa076 100644 --- a/tests/output/bug65593.phpt +++ b/tests/output/bug65593.phpt @@ -1,7 +1,7 @@ --TEST-- Bug #65593 (ob_start(function(){ob_start();});) --FILE-- -<?php +<?php echo "Test\n"; ob_start(function(){ob_start();}); diff --git a/tests/output/flush_basic_001.phpt b/tests/output/flush_basic_001.phpt index 1cc363d63c..fb1ce2c208 100644 --- a/tests/output/flush_basic_001.phpt +++ b/tests/output/flush_basic_001.phpt @@ -2,11 +2,11 @@ Test basic functionality of flush() --FILE-- <?php -/* +/* * proto void flush(void) * Function is implemented in ext/standard/basic_functions.c. */ - + // Verify return type var_dump(flush()); diff --git a/tests/output/flush_error_001.phpt b/tests/output/flush_error_001.phpt index 1f079e6009..e80f69c6b8 100644 --- a/tests/output/flush_error_001.phpt +++ b/tests/output/flush_error_001.phpt @@ -2,7 +2,7 @@ Test wrong number of arguments for flush() (no impact) --FILE-- <?php -/* +/* * proto void flush(void) * Function is implemented in ext/standard/basic_functions.c. */ diff --git a/tests/output/ob_clean_basic_001.phpt b/tests/output/ob_clean_basic_001.phpt index afaa7e2f4a..bd91676b12 100644 --- a/tests/output/ob_clean_basic_001.phpt +++ b/tests/output/ob_clean_basic_001.phpt @@ -1,11 +1,11 @@ --TEST-- -Test ob_clean() function : basic functionality +Test ob_clean() function : basic functionality --FILE-- <?php /* Prototype : proto bool ob_clean(void) - * Description: Clean (delete) the current output buffer + * Description: Clean (delete) the current output buffer * Source code: main/output.c - * Alias to functions: + * Alias to functions: */ echo "*** Testing ob_clean() : basic functionality ***\n"; diff --git a/tests/output/ob_clean_error_001.phpt b/tests/output/ob_clean_error_001.phpt index 8060c2be8b..fffe484074 100644 --- a/tests/output/ob_clean_error_001.phpt +++ b/tests/output/ob_clean_error_001.phpt @@ -1,11 +1,11 @@ --TEST-- -Test ob_clean() function : error conditions +Test ob_clean() function : error conditions --FILE-- <?php /* Prototype : proto bool ob_clean(void) - * Description: Clean (delete) the current output buffer + * Description: Clean (delete) the current output buffer * Source code: main/output.c - * Alias to functions: + * Alias to functions: */ echo "*** Testing ob_clean() : error conditions ***\n"; diff --git a/tests/output/ob_end_clean_basic_001.phpt b/tests/output/ob_end_clean_basic_001.phpt index 54e840bdbd..87942c2f6d 100644 --- a/tests/output/ob_end_clean_basic_001.phpt +++ b/tests/output/ob_end_clean_basic_001.phpt @@ -2,10 +2,10 @@ Test return type and value, as well as basic behaviour, for ob_end_clean() --FILE-- <?php -/* +/* * proto bool ob_end_clean(void) * Function is implemented in main/output.c -*/ +*/ var_dump(ob_end_clean()); diff --git a/tests/output/ob_end_clean_error_001.phpt b/tests/output/ob_end_clean_error_001.phpt index 0279db7b41..09bacaa081 100644 --- a/tests/output/ob_end_clean_error_001.phpt +++ b/tests/output/ob_end_clean_error_001.phpt @@ -2,10 +2,10 @@ Test wrong number of arguments for ob_end_clean() --FILE-- <?php -/* +/* * proto bool ob_end_clean(void) * Function is implemented in main/output.c -*/ +*/ $extra_arg = 1; diff --git a/tests/output/ob_end_flush_basic_001.phpt b/tests/output/ob_end_flush_basic_001.phpt index cba7802761..811d6a0761 100644 --- a/tests/output/ob_end_flush_basic_001.phpt +++ b/tests/output/ob_end_flush_basic_001.phpt @@ -1,11 +1,11 @@ --TEST-- -Test ob_end_flush() function : basic functionality +Test ob_end_flush() function : basic functionality --FILE-- <?php /* Prototype : proto bool ob_end_flush(void) - * Description: Flush (send) the output buffer, and delete current output buffer + * Description: Flush (send) the output buffer, and delete current output buffer * Source code: main/output.c - * Alias to functions: + * Alias to functions: */ echo "*** Testing ob_end_flush() : basic functionality ***\n"; diff --git a/tests/output/ob_end_flush_error_001.phpt b/tests/output/ob_end_flush_error_001.phpt index 2cd9a64e0d..e9c15bd05f 100644 --- a/tests/output/ob_end_flush_error_001.phpt +++ b/tests/output/ob_end_flush_error_001.phpt @@ -1,11 +1,11 @@ --TEST-- -Test ob_end_flush() function : error conditions +Test ob_end_flush() function : error conditions --FILE-- <?php /* Prototype : proto bool ob_end_flush(void) - * Description: Flush (send) the output buffer, and delete current output buffer + * Description: Flush (send) the output buffer, and delete current output buffer * Source code: main/output.c - * Alias to functions: + * Alias to functions: */ echo "*** Testing ob_end_flush() : error conditions ***\n"; diff --git a/tests/output/ob_flush_basic_001.phpt b/tests/output/ob_flush_basic_001.phpt index 57de5e31ad..e53c7e5a23 100644 --- a/tests/output/ob_flush_basic_001.phpt +++ b/tests/output/ob_flush_basic_001.phpt @@ -1,11 +1,11 @@ --TEST-- -Test ob_flush() function : basic functionality +Test ob_flush() function : basic functionality --FILE-- <?php /* Prototype : proto bool ob_flush(void) - * Description: Flush (send) contents of the output buffer. The last buffer content is sent to next buffer + * Description: Flush (send) contents of the output buffer. The last buffer content is sent to next buffer * Source code: main/output.c - * Alias to functions: + * Alias to functions: */ echo "*** Testing ob_flush() : basic functionality ***\n"; diff --git a/tests/output/ob_flush_error_001.phpt b/tests/output/ob_flush_error_001.phpt index f24a19b8ce..6e95810dce 100644 --- a/tests/output/ob_flush_error_001.phpt +++ b/tests/output/ob_flush_error_001.phpt @@ -1,11 +1,11 @@ --TEST-- -Test ob_flush() function : error conditions +Test ob_flush() function : error conditions --FILE-- <?php /* Prototype : proto bool ob_flush(void) - * Description: Flush (send) contents of the output buffer. The last buffer content is sent to next buffer + * Description: Flush (send) contents of the output buffer. The last buffer content is sent to next buffer * Source code: main/output.c - * Alias to functions: + * Alias to functions: */ echo "*** Testing ob_flush() : error conditions ***\n"; diff --git a/tests/output/ob_get_clean_basic_001.phpt b/tests/output/ob_get_clean_basic_001.phpt index 7e1c475c63..2ccf490485 100644 --- a/tests/output/ob_get_clean_basic_001.phpt +++ b/tests/output/ob_get_clean_basic_001.phpt @@ -2,10 +2,10 @@ Test return type and value, as well as basic behaviour, of ob_get_clean() --FILE-- <?php -/* +/* * proto bool ob_get_clean(void) * Function is implemented in main/output.c -*/ +*/ var_dump(ob_get_clean()); diff --git a/tests/output/ob_get_clean_basic_002.phpt b/tests/output/ob_get_clean_basic_002.phpt index c877642e23..9b74438594 100644 --- a/tests/output/ob_get_clean_basic_002.phpt +++ b/tests/output/ob_get_clean_basic_002.phpt @@ -2,10 +2,10 @@ Test basic behaviour of ob_get_clean() --FILE-- <?php -/* +/* * proto bool ob_get_clean(void) * Function is implemented in main/output.c -*/ +*/ ob_start(); diff --git a/tests/output/ob_get_clean_error_001.phpt b/tests/output/ob_get_clean_error_001.phpt index d6e2dd7b61..563e62c35a 100644 --- a/tests/output/ob_get_clean_error_001.phpt +++ b/tests/output/ob_get_clean_error_001.phpt @@ -2,10 +2,10 @@ Test wrong number of arguments for ob_get_clean() --FILE-- <?php -/* +/* * proto bool ob_get_clean(void) * Function is implemented in main/output.c -*/ +*/ $extra_arg = 1; diff --git a/tests/output/ob_get_contents_basic_001.phpt b/tests/output/ob_get_contents_basic_001.phpt index 8d324e5d61..cdf301281e 100644 --- a/tests/output/ob_get_contents_basic_001.phpt +++ b/tests/output/ob_get_contents_basic_001.phpt @@ -1,13 +1,13 @@ --TEST-- Test ob_get_contents() function : basic functionality --CREDITS-- -Iain Lewis <ilewis@php.net> +Iain Lewis <ilewis@php.net> --FILE-- <?php /* Prototype : proto string ob_get_contents(void) - * Description: Return the contents of the output buffer + * Description: Return the contents of the output buffer * Source code: main/output.c - * Alias to functions: + * Alias to functions: */ @@ -35,14 +35,14 @@ ob_end_flush(); echo "\ncheck that contents disappear after a flush\n"; ob_start(); -echo "Hello World\n"; +echo "Hello World\n"; ob_flush(); var_dump(ob_get_contents()); ob_end_flush(); echo "\ncheck that no contents found after an end\n"; ob_start(); -echo "Hello World\n"; +echo "Hello World\n"; ob_end_flush(); var_dump(ob_get_contents()); diff --git a/tests/output/ob_get_contents_error_001.phpt b/tests/output/ob_get_contents_error_001.phpt index 94e3f31368..2c1c043ba7 100644 --- a/tests/output/ob_get_contents_error_001.phpt +++ b/tests/output/ob_get_contents_error_001.phpt @@ -1,13 +1,13 @@ --TEST-- Test ob_get_contents() function : error cases --CREDITS-- -Iain Lewis <ilewis@php.net> +Iain Lewis <ilewis@php.net> --FILE-- <?php /* Prototype : proto string ob_get_contents(void) - * Description: Return the contents of the output buffer + * Description: Return the contents of the output buffer * Source code: main/output.c - * Alias to functions: + * Alias to functions: */ diff --git a/tests/output/ob_get_length_basic_001.phpt b/tests/output/ob_get_length_basic_001.phpt index ef52044c0c..892d106719 100644 --- a/tests/output/ob_get_length_basic_001.phpt +++ b/tests/output/ob_get_length_basic_001.phpt @@ -2,10 +2,10 @@ Test return type and value, as well as basic behaviour, of ob_get_length() --FILE-- <?php -/* +/* * proto int ob_get_length(void) * Function is implemented in main/output.c -*/ +*/ echo "No output buffers\n"; var_dump(ob_get_length()); diff --git a/tests/output/ob_get_length_error_001.phpt b/tests/output/ob_get_length_error_001.phpt index 3de0cb10a8..8e4318122b 100644 --- a/tests/output/ob_get_length_error_001.phpt +++ b/tests/output/ob_get_length_error_001.phpt @@ -2,10 +2,10 @@ Test wrong number of arguments for ob_get_length() --FILE-- <?php -/* +/* * proto int ob_get_length(void) * Function is implemented in main/output.c -*/ +*/ $extra_arg = 1; diff --git a/tests/output/ob_get_level_basic_001.phpt b/tests/output/ob_get_level_basic_001.phpt index 65f3291355..4a6c84785b 100644 --- a/tests/output/ob_get_level_basic_001.phpt +++ b/tests/output/ob_get_level_basic_001.phpt @@ -1,11 +1,11 @@ --TEST-- -Test ob_get_level() function : basic functionality +Test ob_get_level() function : basic functionality --FILE-- <?php /* Prototype : proto int ob_get_level(void) - * Description: Return the nesting level of the output buffer + * Description: Return the nesting level of the output buffer * Source code: main/output.c - * Alias to functions: + * Alias to functions: */ echo "*** Testing ob_get_level() : basic functionality ***\n"; diff --git a/tests/output/ob_get_level_error_001.phpt b/tests/output/ob_get_level_error_001.phpt index 9694da54a0..00e9eca555 100644 --- a/tests/output/ob_get_level_error_001.phpt +++ b/tests/output/ob_get_level_error_001.phpt @@ -1,11 +1,11 @@ --TEST-- -Test ob_get_level() function : error conditions +Test ob_get_level() function : error conditions --FILE-- <?php /* Prototype : proto int ob_get_level(void) - * Description: Return the nesting level of the output buffer + * Description: Return the nesting level of the output buffer * Source code: main/output.c - * Alias to functions: + * Alias to functions: */ echo "*** Testing ob_get_level() : error conditions ***\n"; diff --git a/tests/output/ob_implicit_flush_basic_001.phpt b/tests/output/ob_implicit_flush_basic_001.phpt index 2bbf8fd45a..780eb6dfbb 100644 --- a/tests/output/ob_implicit_flush_basic_001.phpt +++ b/tests/output/ob_implicit_flush_basic_001.phpt @@ -3,9 +3,9 @@ Test ob_implicit_flush() function : check return value (always null). --FILE-- <?php /* Prototype : proto void ob_implicit_flush([int flag]) - * Description: Turn implicit flush on/off and is equivalent to calling flush() after every output call + * Description: Turn implicit flush on/off and is equivalent to calling flush() after every output call * Source code: main/output.c - * Alias to functions: + * Alias to functions: */ echo "*** Testing ob_implicit_flush() : check return value ***\n"; diff --git a/tests/output/ob_implicit_flush_basic_002.phpt b/tests/output/ob_implicit_flush_basic_002.phpt index df985a49b9..37d10ba640 100644 --- a/tests/output/ob_implicit_flush_basic_002.phpt +++ b/tests/output/ob_implicit_flush_basic_002.phpt @@ -3,9 +3,9 @@ Test ob_implicit_flush() function : ensure implicit flushing does not apply to u --FILE-- <?php /* Prototype : proto void ob_implicit_flush([int flag]) - * Description: Turn implicit flush on/off and is equivalent to calling flush() after every output call + * Description: Turn implicit flush on/off and is equivalent to calling flush() after every output call * Source code: main/output.c - * Alias to functions: + * Alias to functions: */ echo "*** Testing ob_implicit_flush() : ensure implicit flushing does not apply to user buffers. ***\n"; diff --git a/tests/output/ob_implicit_flush_error_001.phpt b/tests/output/ob_implicit_flush_error_001.phpt index 1fac1b34d9..63c892e0c4 100644 --- a/tests/output/ob_implicit_flush_error_001.phpt +++ b/tests/output/ob_implicit_flush_error_001.phpt @@ -3,9 +3,9 @@ Test ob_implicit_flush() function : wrong number of arguments --FILE-- <?php /* Prototype : proto void ob_implicit_flush([int flag]) - * Description: Turn implicit flush on/off and is equivalent to calling flush() after every output call + * Description: Turn implicit flush on/off and is equivalent to calling flush() after every output call * Source code: main/output.c - * Alias to functions: + * Alias to functions: */ echo "*** Testing ob_implicit_flush() : error conditions ***\n"; diff --git a/tests/output/ob_implicit_flush_variation_001.phpt b/tests/output/ob_implicit_flush_variation_001.phpt index 8f2442f8f8..d6d3a45e01 100644 --- a/tests/output/ob_implicit_flush_variation_001.phpt +++ b/tests/output/ob_implicit_flush_variation_001.phpt @@ -1,13 +1,13 @@ --TEST-- -Test ob_implicit_flush() function : usage variation +Test ob_implicit_flush() function : usage variation --SKIPIF-- <?php if (PHP_INT_SIZE != 8) die("skip this test is for 64-bit only"); --FILE-- <?php /* Prototype : void ob_implicit_flush([int flag]) - * Description: Turn implicit flush on/off and is equivalent to calling flush() after every output call + * Description: Turn implicit flush on/off and is equivalent to calling flush() after every output call * Source code: main/output.c - * Alias to functions: + * Alias to functions: */ echo "*** Testing ob_implicit_flush() : usage variation ***\n"; diff --git a/tests/output/ob_start_basic_001.phpt b/tests/output/ob_start_basic_001.phpt index 02275c62c5..0b06f6077f 100644 --- a/tests/output/ob_start_basic_001.phpt +++ b/tests/output/ob_start_basic_001.phpt @@ -2,10 +2,10 @@ Test return type and value for ob_start() --FILE-- <?php -/* +/* * proto bool ob_start([ string|array user_function [, int chunk_size [, bool erase]]]) * Function is implemented in main/output.c -*/ +*/ var_dump(ob_start()); diff --git a/tests/output/ob_start_basic_004.phpt b/tests/output/ob_start_basic_004.phpt index 9fe19e9b0f..eff1204236 100644 --- a/tests/output/ob_start_basic_004.phpt +++ b/tests/output/ob_start_basic_004.phpt @@ -1,13 +1,13 @@ --TEST-- -ob_start() chunk_size: confirm buffer is flushed after any output call that causes its length to equal or exceed chunk_size. +ob_start() chunk_size: confirm buffer is flushed after any output call that causes its length to equal or exceed chunk_size. --INI-- opcache.optimization_level=0 --FILE-- <?php -/* +/* * proto bool ob_start([ string|array user_function [, int chunk_size [, bool erase]]]) * Function is implemented in main/output.c -*/ +*/ // In HEAD, $chunk_size value of 1 should not have any special behaviour (http://marc.info/?l=php-internals&m=123476465621346&w=2). function callback($string) { global $callback_invocations; diff --git a/tests/output/ob_start_basic_005.phpt b/tests/output/ob_start_basic_005.phpt index 4048ad25a2..7cab6ed35f 100644 --- a/tests/output/ob_start_basic_005.phpt +++ b/tests/output/ob_start_basic_005.phpt @@ -2,10 +2,10 @@ ob_start(): non-static method as static callbacks. --FILE-- <?php -/* +/* * proto bool ob_start([ string|array user_function [, int chunk_size [, bool erase]]]) * Function is implemented in main/output.c -*/ +*/ Class C { function h($string) { diff --git a/tests/output/ob_start_basic_006.phpt b/tests/output/ob_start_basic_006.phpt index 464e71be33..d4d0fcc149 100644 --- a/tests/output/ob_start_basic_006.phpt +++ b/tests/output/ob_start_basic_006.phpt @@ -2,10 +2,10 @@ ob_start(): ensure multiple buffer initialization with a single call using arrays is not supported on PHP6 (http://bugs.php.net/42641) --FILE-- <?php -/* +/* * proto bool ob_start([ string|array user_function [, int chunk_size [, bool erase]]]) * Function is implemented in main/output.c -*/ +*/ function f($string) { static $i=0; @@ -27,7 +27,7 @@ Class C { $len = strlen($string); return "C::g[call:$i; len:$len] - $string\n"; } - + function h($string) { static $i=0; $i++; diff --git a/tests/output/ob_start_callbacks.phpt b/tests/output/ob_start_callbacks.phpt index da52d85f7f..6815bccd63 100644 --- a/tests/output/ob_start_callbacks.phpt +++ b/tests/output/ob_start_callbacks.phpt @@ -1,7 +1,7 @@ --TEST-- Test ob_start() with callbacks in variables --FILE-- -<?php +<?php // Closure in variable $a = function ($s) { return strtoupper($s); }; diff --git a/tests/output/ob_start_error_001.phpt b/tests/output/ob_start_error_001.phpt index 92372c7747..29288e2028 100644 --- a/tests/output/ob_start_error_001.phpt +++ b/tests/output/ob_start_error_001.phpt @@ -2,10 +2,10 @@ Test wrong number of arguments and wrong arg types for ob_start() --FILE-- <?php -/* +/* * proto bool ob_start([ string|array user_function [, int chunk_size [, bool erase]]]) * Function is implemented in main/output.c -*/ +*/ function justPrint($str) { return $str; diff --git a/tests/output/ob_start_error_002.phpt b/tests/output/ob_start_error_002.phpt index 38c789908d..7cac3ee4b3 100644 --- a/tests/output/ob_start_error_002.phpt +++ b/tests/output/ob_start_error_002.phpt @@ -2,10 +2,10 @@ Test wrong number of arguments and wrong arg types for ob_start() --FILE-- <?php -/* +/* * proto bool ob_start([ string|array user_function [, int chunk_size [, bool erase]]]) * Function is implemented in main/output.c -*/ +*/ Class C { static function f($str) { diff --git a/tests/output/ob_start_error_003.phpt b/tests/output/ob_start_error_003.phpt index 7fa292a739..3af56f7a2b 100644 --- a/tests/output/ob_start_error_003.phpt +++ b/tests/output/ob_start_error_003.phpt @@ -2,10 +2,10 @@ Test ob_start() with object supplied but no method. --FILE-- <?php -/* +/* * proto bool ob_start([ string|array user_function [, int chunk_size [, bool erase]]]) * Function is implemented in main/output.c -*/ +*/ Class C { } diff --git a/tests/output/ob_start_error_004.phpt b/tests/output/ob_start_error_004.phpt index 7ddf998557..83f5dc8d1c 100644 --- a/tests/output/ob_start_error_004.phpt +++ b/tests/output/ob_start_error_004.phpt @@ -2,10 +2,10 @@ Test ob_start() with non existent callback method. --FILE-- <?php -/* +/* * proto bool ob_start([ string|array user_function [, int chunk_size [, bool erase]]]) * Function is implemented in main/output.c -*/ +*/ Class C { } diff --git a/tests/output/ob_start_error_005.phpt b/tests/output/ob_start_error_005.phpt index 134f2249b7..d6f9dc4c10 100644 --- a/tests/output/ob_start_error_005.phpt +++ b/tests/output/ob_start_error_005.phpt @@ -3,10 +3,10 @@ ob_start(): ensure buffers can't be added from within callback. --FILE-- <?php -/* +/* * proto bool ob_start([ string|array user_function [, int chunk_size [, bool erase]]]) * Function is implemented in main/output.c -*/ +*/ function f($str) { ob_start(); diff --git a/tests/run-test/test005.phpt b/tests/run-test/test005.phpt index ef644a4fb1..a95281fc13 100644 --- a/tests/run-test/test005.phpt +++ b/tests/run-test/test005.phpt @@ -12,7 +12,7 @@ track_errors=1 // // We check the general ini settings which affect error handling // and than verify if a message is given by a division by zero. -// EXPECTF is used here since the error format may change but ut +// EXPECTF is used here since the error format may change but ut // should always contain 'Division by zero'. var_dump(ini_get('display_errors')); var_dump(ini_get('error_reporting')); diff --git a/tests/run-test/test008.phpt b/tests/run-test/test008.phpt index 41d22d8e71..c289e7a696 100644 --- a/tests/run-test/test008.phpt +++ b/tests/run-test/test008.phpt @@ -12,7 +12,7 @@ track_errors=1 // // We check the general ini settings which affect error handling // and than verify if a message is given by a division by zero. -// EXPECTF is used here since the error format may change but ut +// EXPECTF is used here since the error format may change but ut // should always contain 'Division by zero'. var_dump(ini_get('display_errors')); var_dump(ini_get('error_reporting')); diff --git a/tests/run-test/test008a.phpt b/tests/run-test/test008a.phpt index 9814fa12f7..d247eb36c2 100644 --- a/tests/run-test/test008a.phpt +++ b/tests/run-test/test008a.phpt @@ -12,7 +12,7 @@ track_errors=1 // // We check the general ini settings which affect error handling // and than verify if a message is given by a division by zero. -// EXPECTF is used here since the error format may change but ut +// EXPECTF is used here since the error format may change but ut // should always contain 'Division by zero'. var_dump(ini_get('display_errors')); var_dump(ini_get('error_reporting')); diff --git a/tests/security/open_basedir_dir.phpt b/tests/security/open_basedir_dir.phpt index b1d6272bdc..6dababa54b 100644 --- a/tests/security/open_basedir_dir.phpt +++ b/tests/security/open_basedir_dir.phpt @@ -8,7 +8,7 @@ require_once "open_basedir.inc"; $initdir = getcwd(); test_open_basedir_before("dir"); -test_open_basedir_error("dir"); +test_open_basedir_error("dir"); var_dump(dir($initdir."/test/ok/")); var_dump(dir($initdir."/test/ok")); diff --git a/tests/security/open_basedir_disk_free_space.phpt b/tests/security/open_basedir_disk_free_space.phpt index 365300ae61..e04ed410c4 100644 --- a/tests/security/open_basedir_disk_free_space.phpt +++ b/tests/security/open_basedir_disk_free_space.phpt @@ -7,7 +7,7 @@ open_basedir=. require_once "open_basedir.inc"; $initdir = getcwd(); test_open_basedir_before("disk_free_space"); -test_open_basedir_error("disk_free_space"); +test_open_basedir_error("disk_free_space"); var_dump(disk_free_space($initdir."/test/ok")); test_open_basedir_after("disk_free_space"); diff --git a/tests/security/open_basedir_file.phpt b/tests/security/open_basedir_file.phpt index ad222e894b..e319482f7d 100644 --- a/tests/security/open_basedir_file.phpt +++ b/tests/security/open_basedir_file.phpt @@ -8,7 +8,7 @@ require_once "open_basedir.inc"; $initdir = getcwd(); test_open_basedir_before("file"); test_open_basedir_error("file"); - + var_dump(file("ok.txt")); var_dump(file("../ok/ok.txt")); var_dump(file($initdir."/test/ok/ok.txt")); diff --git a/tests/security/open_basedir_file_get_contents.phpt b/tests/security/open_basedir_file_get_contents.phpt index 8ee5ddb793..b5a34de074 100644 --- a/tests/security/open_basedir_file_get_contents.phpt +++ b/tests/security/open_basedir_file_get_contents.phpt @@ -8,7 +8,7 @@ require_once "open_basedir.inc"; $initdir = getcwd(); test_open_basedir_before("file_get_contents"); test_open_basedir_error("file_get_contents"); - + var_dump(file_get_contents("ok.txt")); var_dump(file_get_contents("../ok/ok.txt")); var_dump(file_get_contents($initdir."/test/ok/ok.txt")); diff --git a/tests/security/open_basedir_is_executable.phpt b/tests/security/open_basedir_is_executable.phpt index 375d4277cd..f0d8f20ba4 100644 --- a/tests/security/open_basedir_is_executable.phpt +++ b/tests/security/open_basedir_is_executable.phpt @@ -7,7 +7,7 @@ open_basedir=. require_once "open_basedir.inc"; $initdir = getcwd(); test_open_basedir_before("is_executable"); -test_open_basedir_error("is_executable"); +test_open_basedir_error("is_executable"); var_dump(is_executable("ok.txt")); var_dump(is_executable("../ok/ok.txt")); diff --git a/tests/security/open_basedir_opendir.phpt b/tests/security/open_basedir_opendir.phpt index 774b853569..fc3111e361 100644 --- a/tests/security/open_basedir_opendir.phpt +++ b/tests/security/open_basedir_opendir.phpt @@ -7,7 +7,7 @@ open_basedir=. require_once "open_basedir.inc"; $initdir = getcwd(); test_open_basedir_before("opendir"); -test_open_basedir_error("opendir"); +test_open_basedir_error("opendir"); var_dump(opendir($initdir."/test/ok/")); var_dump(opendir($initdir."/test/ok")); diff --git a/tests/security/open_basedir_scandir.phpt b/tests/security/open_basedir_scandir.phpt index caffaa1e5d..3ef9b153f4 100644 --- a/tests/security/open_basedir_scandir.phpt +++ b/tests/security/open_basedir_scandir.phpt @@ -7,7 +7,7 @@ open_basedir=. require_once "open_basedir.inc"; $initdir = getcwd(); test_open_basedir_before("scandir"); -test_open_basedir_error("scandir"); +test_open_basedir_error("scandir"); var_dump(scandir($initdir."/test/ok/")); var_dump(scandir($initdir."/test/ok")); diff --git a/tests/strings/001.phpt b/tests/strings/001.phpt index 98ceceb350..bf1fb67711 100644 --- a/tests/strings/001.phpt +++ b/tests/strings/001.phpt @@ -1,7 +1,7 @@ --TEST-- String functions --FILE-- -<?php +<?php error_reporting(0); diff --git a/tests/strings/002.phpt b/tests/strings/002.phpt index 7b95a25645..5e82091088 100644 --- a/tests/strings/002.phpt +++ b/tests/strings/002.phpt @@ -1,7 +1,7 @@ --TEST-- Formatted print functions --FILE-- -<?php +<?php error_reporting(0); $fp = fopen("php://stdout", "w") or die("Arrggsgg!!"); diff --git a/tests/strings/004.phpt b/tests/strings/004.phpt index 7bcb452937..44bb000d14 100644 --- a/tests/strings/004.phpt +++ b/tests/strings/004.phpt @@ -7,7 +7,7 @@ highlight.keyword=#007700 highlight.default=#0000BB highlight.html=#000000 --FILE-- -<?php +<?php $var = highlight_string("<br /><?php echo \"foo\"; ?><br />"); $var = highlight_string("<br /><?php echo \"bar\"; ?><br />", TRUE); echo "\n[$var]\n"; diff --git a/tests/strings/bug22592.phpt b/tests/strings/bug22592.phpt index 3443c32859..c66e27d880 100644 --- a/tests/strings/bug22592.phpt +++ b/tests/strings/bug22592.phpt @@ -13,7 +13,7 @@ $correct[1] = '*'; $correct[3] = '*'; $correct[5] = '*'; -// This produces the +// This produces the $wrong[1] = $wrong[3] = $wrong[5] = '*'; var_dump($correct); |