summaryrefslogtreecommitdiff
path: root/ext/standard/tests/array
diff options
context:
space:
mode:
authorNikita Popov <nikita.ppv@gmail.com>2019-02-01 12:57:55 +0100
committerNikita Popov <nikita.ppv@gmail.com>2019-02-05 09:38:55 +0100
commit8bc663f43bb3f556866a2f804c422646c4da56f2 (patch)
tree8b15beb7927b03369e69ec0545c354a7f7f9371b /ext/standard/tests/array
parentda919a8b658bf65ff0705bc03c28c7be085d6329 (diff)
downloadphp-git-8bc663f43bb3f556866a2f804c422646c4da56f2.tar.gz
Remove zpp variation tests
Diffstat (limited to 'ext/standard/tests/array')
-rw-r--r--ext/standard/tests/array/array_change_key_case_variation1.phpt223
-rw-r--r--ext/standard/tests/array/array_change_key_case_variation2.phpt289
-rw-r--r--ext/standard/tests/array/array_chunk_variation1.phpt325
-rw-r--r--ext/standard/tests/array/array_chunk_variation2.phpt429
-rw-r--r--ext/standard/tests/array/array_chunk_variation3.phpt268
-rw-r--r--ext/standard/tests/array/array_combine_variation1.phpt198
-rw-r--r--ext/standard/tests/array/array_combine_variation2.phpt198
-rw-r--r--ext/standard/tests/array/array_fill_variation1.phpt244
-rw-r--r--ext/standard/tests/array/array_fill_variation1_64bit.phpt247
-rw-r--r--ext/standard/tests/array/array_fill_variation2.phpt198
-rw-r--r--ext/standard/tests/array/array_filter_variation1.phpt195
-rw-r--r--ext/standard/tests/array/array_filter_variation2.phpt184
-rw-r--r--ext/standard/tests/array/array_flip_variation1.phpt179
-rw-r--r--ext/standard/tests/array/array_key_exists_variation2.phpt224
-rw-r--r--ext/standard/tests/array/array_map_variation18.phpt205
-rw-r--r--ext/standard/tests/array/array_pad_variation1.phpt270
-rw-r--r--ext/standard/tests/array/array_pad_variation2.phpt258
-rw-r--r--ext/standard/tests/array/array_product_variation5.phpt223
-rw-r--r--ext/standard/tests/array/array_push_variation1.phpt225
-rw-r--r--ext/standard/tests/array/array_rand_variation1.phpt216
-rw-r--r--ext/standard/tests/array/array_rand_variation2.phpt216
-rw-r--r--ext/standard/tests/array/array_reverse_variation1.phpt340
-rw-r--r--ext/standard/tests/array/array_reverse_variation2.phpt414
-rw-r--r--ext/standard/tests/array/array_shift_variation1.phpt218
-rw-r--r--ext/standard/tests/array/array_slice_variation4.phpt326
-rw-r--r--ext/standard/tests/array/array_sum_variation1.phpt179
-rw-r--r--ext/standard/tests/array/array_unique_variation1.phpt195
-rw-r--r--ext/standard/tests/array/array_unshift_variation1.phpt338
-rw-r--r--ext/standard/tests/array/array_values_variation1.phpt223
-rw-r--r--ext/standard/tests/array/array_walk_recursive_variation1.phpt250
-rw-r--r--ext/standard/tests/array/array_walk_recursive_variation2.phpt268
-rw-r--r--ext/standard/tests/array/array_walk_variation1.phpt250
-rw-r--r--ext/standard/tests/array/array_walk_variation2.phpt268
-rw-r--r--ext/standard/tests/array/arsort_variation1.phpt399
-rw-r--r--ext/standard/tests/array/arsort_variation2.phpt308
-rw-r--r--ext/standard/tests/array/asort_variation1.phpt399
-rw-r--r--ext/standard/tests/array/asort_variation2.phpt308
-rw-r--r--ext/standard/tests/array/count_variation1.phpt218
-rw-r--r--ext/standard/tests/array/count_variation2.phpt189
-rw-r--r--ext/standard/tests/array/current_variation1.phpt217
-rw-r--r--ext/standard/tests/array/end_variation1.phpt220
-rw-r--r--ext/standard/tests/array/key_variation1.phpt220
-rw-r--r--ext/standard/tests/array/krsort_variation1.phpt397
-rw-r--r--ext/standard/tests/array/krsort_variation2.phpt307
-rw-r--r--ext/standard/tests/array/ksort_variation1.phpt397
-rw-r--r--ext/standard/tests/array/ksort_variation2.phpt307
-rw-r--r--ext/standard/tests/array/natcasesort_variation1.phpt222
-rw-r--r--ext/standard/tests/array/next_variation1.phpt219
-rw-r--r--ext/standard/tests/array/prev_variation1.phpt219
-rw-r--r--ext/standard/tests/array/reset_variation1.phpt219
-rw-r--r--ext/standard/tests/array/rsort_variation1.phpt513
-rw-r--r--ext/standard/tests/array/rsort_variation2.phpt485
-rw-r--r--ext/standard/tests/array/shuffle_variation1.phpt213
-rw-r--r--ext/standard/tests/array/sort_variation1.phpt398
-rw-r--r--ext/standard/tests/array/sort_variation2.phpt311
-rw-r--r--ext/standard/tests/array/uasort_variation1.phpt188
-rw-r--r--ext/standard/tests/array/uasort_variation2.phpt212
-rw-r--r--ext/standard/tests/array/uksort_variation1.phpt224
-rw-r--r--ext/standard/tests/array/uksort_variation2.phpt224
-rw-r--r--ext/standard/tests/array/usort_variation1.phpt236
-rw-r--r--ext/standard/tests/array/usort_variation2.phpt242
61 files changed, 0 insertions, 16294 deletions
diff --git a/ext/standard/tests/array/array_change_key_case_variation1.phpt b/ext/standard/tests/array/array_change_key_case_variation1.phpt
deleted file mode 100644
index 14626deb86..0000000000
--- a/ext/standard/tests/array/array_change_key_case_variation1.phpt
+++ /dev/null
@@ -1,223 +0,0 @@
---TEST--
-Test array_change_key_case() function : usage variations - Pass different data types as $input arg
---FILE--
-<?php
-/* Prototype : array array_change_key_case(array $input [, int $case])
- * Description: Returns an array with all string keys lowercased [or uppercased]
- * Source code: ext/standard/array.c
- */
-
-/*
- * Pass different data types as $input argument to test behaviour of array_change_key_case()
- */
-
-echo "*** Testing array_change_key_case() : usage variations ***\n";
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// get a class
-class classA
-{
- public function __toString() {
- return "Class A object";
- }
-}
-
-// heredoc string
-$heredoc = <<<EOT
-hello world
-EOT;
-
-// get a resource variable
-$fp = fopen(__FILE__, "r");
-
-// unexpected values to be passed to $input argument
-$inputs = array(
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 12.3456789000e10,
- 12.3456789000E-10,
- .5,
-
- // null data
-/*10*/ NULL,
- null,
-
- // boolean data
-/*12*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*16*/ "",
- '',
- array(),
-
- // string data
-/*19*/ "string",
- 'string',
- $heredoc,
-
- // object data
-/*22*/ new classA(),
-
- // undefined data
-/*23*/ @$undefined_var,
-
- // unset data
-/*24*/ @$unset_var,
-
- // resource variable
-/*25*/ $fp
-);
-
-// loop through each element of $inputs to check the behavior of array_change_key_case()
-$iterator = 1;
-foreach($inputs as $input) {
- echo "\n-- Iteration $iterator --\n";
- var_dump( array_change_key_case($input) );
- $iterator++;
-};
-
-fclose($fp);
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing array_change_key_case() : usage variations ***
-
--- Iteration 1 --
-
-Warning: array_change_key_case() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 2 --
-
-Warning: array_change_key_case() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 3 --
-
-Warning: array_change_key_case() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 4 --
-
-Warning: array_change_key_case() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 5 --
-
-Warning: array_change_key_case() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 6 --
-
-Warning: array_change_key_case() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 7 --
-
-Warning: array_change_key_case() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 8 --
-
-Warning: array_change_key_case() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 9 --
-
-Warning: array_change_key_case() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 10 --
-
-Warning: array_change_key_case() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 11 --
-
-Warning: array_change_key_case() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 12 --
-
-Warning: array_change_key_case() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 13 --
-
-Warning: array_change_key_case() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 14 --
-
-Warning: array_change_key_case() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 15 --
-
-Warning: array_change_key_case() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 16 --
-
-Warning: array_change_key_case() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 17 --
-
-Warning: array_change_key_case() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 18 --
-array(0) {
-}
-
--- Iteration 19 --
-
-Warning: array_change_key_case() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 20 --
-
-Warning: array_change_key_case() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 21 --
-
-Warning: array_change_key_case() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 22 --
-
-Warning: array_change_key_case() expects parameter 1 to be array, object given in %s on line %d
-NULL
-
--- Iteration 23 --
-
-Warning: array_change_key_case() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 24 --
-
-Warning: array_change_key_case() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 25 --
-
-Warning: array_change_key_case() expects parameter 1 to be array, resource given in %s on line %d
-NULL
-Done
diff --git a/ext/standard/tests/array/array_change_key_case_variation2.phpt b/ext/standard/tests/array/array_change_key_case_variation2.phpt
deleted file mode 100644
index b0b90bd926..0000000000
--- a/ext/standard/tests/array/array_change_key_case_variation2.phpt
+++ /dev/null
@@ -1,289 +0,0 @@
---TEST--
-Test array_change_key_case() function : usage variations - Pass different data types as $case arg
---SKIPIF--
-<?php if (PHP_INT_SIZE != 8) die("skip this test is for 64-bit only");
---FILE--
-<?php
-/* Prototype : array array_change_key_case(array $input [, int $case])
- * Description: Returns an array with all string keys lowercased [or uppercased]
- * Source code: ext/standard/array.c
- */
-
-/*
- * Pass different data types as $case argument to array_change_key_case() to test behaviour
- * Where possible, CASE_UPPER has been entered as a string value
- */
-
-echo "*** Testing array_change_key_case() : usage variations ***\n";
-
-// Initialise function arguments not being substituted
-$array = array ('one' => 1, 'TWO' => 2, 'Three' => 3);
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// heredoc string
-$heredoc = <<<EOT
-CASE_UPPER
-EOT;
-
-// get a resource variable
-$fp = fopen(__FILE__, "r");
-
-// unexpected values to be passed to $case argument
-$inputs = array(
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 12.3456789000e10,
- 12.3456789000E-10,
- .5,
-
- // null data
-/*10*/ NULL,
- null,
-
- // boolean data
-/*12*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*16*/ "",
- '',
- array(),
-
- // string data
-/*19*/ "CASE_UPPER",
- 'CASE_UPPER',
- $heredoc,
-
- // undefined data
-/*22*/ @$undefined_var,
-
- // unset data
-/*23*/ @$unset_var,
-);
-
-// loop through each element of $inputs to check the behavior of array_change_key_case()
-$iterator = 1;
-foreach($inputs as $input) {
- echo "\n-- Iteration $iterator --\n";
- var_dump( array_change_key_case($array, $input) );
- $iterator++;
-};
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing array_change_key_case() : usage variations ***
-
--- Iteration 1 --
-array(3) {
- ["one"]=>
- int(1)
- ["two"]=>
- int(2)
- ["three"]=>
- int(3)
-}
-
--- Iteration 2 --
-array(3) {
- ["ONE"]=>
- int(1)
- ["TWO"]=>
- int(2)
- ["THREE"]=>
- int(3)
-}
-
--- Iteration 3 --
-array(3) {
- ["ONE"]=>
- int(1)
- ["TWO"]=>
- int(2)
- ["THREE"]=>
- int(3)
-}
-
--- Iteration 4 --
-array(3) {
- ["ONE"]=>
- int(1)
- ["TWO"]=>
- int(2)
- ["THREE"]=>
- int(3)
-}
-
--- Iteration 5 --
-array(3) {
- ["ONE"]=>
- int(1)
- ["TWO"]=>
- int(2)
- ["THREE"]=>
- int(3)
-}
-
--- Iteration 6 --
-array(3) {
- ["ONE"]=>
- int(1)
- ["TWO"]=>
- int(2)
- ["THREE"]=>
- int(3)
-}
-
--- Iteration 7 --
-array(3) {
- ["ONE"]=>
- int(1)
- ["TWO"]=>
- int(2)
- ["THREE"]=>
- int(3)
-}
-
--- Iteration 8 --
-array(3) {
- ["one"]=>
- int(1)
- ["two"]=>
- int(2)
- ["three"]=>
- int(3)
-}
-
--- Iteration 9 --
-array(3) {
- ["one"]=>
- int(1)
- ["two"]=>
- int(2)
- ["three"]=>
- int(3)
-}
-
--- Iteration 10 --
-array(3) {
- ["one"]=>
- int(1)
- ["two"]=>
- int(2)
- ["three"]=>
- int(3)
-}
-
--- Iteration 11 --
-array(3) {
- ["one"]=>
- int(1)
- ["two"]=>
- int(2)
- ["three"]=>
- int(3)
-}
-
--- Iteration 12 --
-array(3) {
- ["ONE"]=>
- int(1)
- ["TWO"]=>
- int(2)
- ["THREE"]=>
- int(3)
-}
-
--- Iteration 13 --
-array(3) {
- ["one"]=>
- int(1)
- ["two"]=>
- int(2)
- ["three"]=>
- int(3)
-}
-
--- Iteration 14 --
-array(3) {
- ["ONE"]=>
- int(1)
- ["TWO"]=>
- int(2)
- ["THREE"]=>
- int(3)
-}
-
--- Iteration 15 --
-array(3) {
- ["one"]=>
- int(1)
- ["two"]=>
- int(2)
- ["three"]=>
- int(3)
-}
-
--- Iteration 16 --
-
-Warning: array_change_key_case() expects parameter 2 to be int, string given in %s on line %d
-NULL
-
--- Iteration 17 --
-
-Warning: array_change_key_case() expects parameter 2 to be int, string given in %s on line %d
-NULL
-
--- Iteration 18 --
-
-Warning: array_change_key_case() expects parameter 2 to be int, array given in %s on line %d
-NULL
-
--- Iteration 19 --
-
-Warning: array_change_key_case() expects parameter 2 to be int, string given in %s on line %d
-NULL
-
--- Iteration 20 --
-
-Warning: array_change_key_case() expects parameter 2 to be int, string given in %s on line %d
-NULL
-
--- Iteration 21 --
-
-Warning: array_change_key_case() expects parameter 2 to be int, string given in %s on line %d
-NULL
-
--- Iteration 22 --
-array(3) {
- ["one"]=>
- int(1)
- ["two"]=>
- int(2)
- ["three"]=>
- int(3)
-}
-
--- Iteration 23 --
-array(3) {
- ["one"]=>
- int(1)
- ["two"]=>
- int(2)
- ["three"]=>
- int(3)
-}
-Done
diff --git a/ext/standard/tests/array/array_chunk_variation1.phpt b/ext/standard/tests/array/array_chunk_variation1.phpt
deleted file mode 100644
index e4437ccf1a..0000000000
--- a/ext/standard/tests/array/array_chunk_variation1.phpt
+++ /dev/null
@@ -1,325 +0,0 @@
---TEST--
-Test array_chunk() function : usage variations - unexpected values for 'array' argument
---FILE--
-<?php
-/* Prototype : proto array array_chunk(array $array, int $size [, bool $preserve_keys])
- * Description: Split array into chunks
- * Chunks an array into size large chunks.
- * Source code: ext/standard/array.c
-*/
-
-/*
-* Testing array_chunk() function with unexpected values for 'array' argument
-*/
-
-echo "*** Testing array_chunk() : usage variations ***\n";
-
-// Initialise function arguments
-$size = 10;
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-//array of values to iterate over
-$values = array(
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 10.5e10,
- 10.6E-10,
- .5,
-
- // null data
-/*10*/ NULL,
- null,
-
- // boolean data
-/*12*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*16*/ "",
- '',
-
- // string data
-/*18*/ "string",
- 'string',
-
- // object data
-/*20*/ new stdclass(),
-
- // undefined data
-/*21*/ @undefined_var,
-
- // unset data
-/*22*/ @unset_var
-
-);
-
-$count = 1;
-// loop through each element of the array for input
-foreach($values as $value){
- echo "\n-- Iteration $count --\n";
- var_dump( array_chunk($value, $size) );
- var_dump( array_chunk($value, $size, true) );
- var_dump( array_chunk($value, $size, false) );
- $count++;
-}
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing array_chunk() : usage variations ***
-
--- Iteration 1 --
-
-Warning: array_chunk() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 2 --
-
-Warning: array_chunk() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 3 --
-
-Warning: array_chunk() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 4 --
-
-Warning: array_chunk() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 5 --
-
-Warning: array_chunk() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 6 --
-
-Warning: array_chunk() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 7 --
-
-Warning: array_chunk() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 8 --
-
-Warning: array_chunk() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 9 --
-
-Warning: array_chunk() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 10 --
-
-Warning: array_chunk() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 11 --
-
-Warning: array_chunk() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 12 --
-
-Warning: array_chunk() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 13 --
-
-Warning: array_chunk() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 14 --
-
-Warning: array_chunk() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 15 --
-
-Warning: array_chunk() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 16 --
-
-Warning: array_chunk() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 17 --
-
-Warning: array_chunk() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 18 --
-
-Warning: array_chunk() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 19 --
-
-Warning: array_chunk() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 20 --
-
-Warning: array_chunk() expects parameter 1 to be array, object given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, object given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, object given in %s on line %d
-NULL
-
--- Iteration 21 --
-
-Warning: array_chunk() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 22 --
-
-Warning: array_chunk() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 1 to be array, string given in %s on line %d
-NULL
-Done
diff --git a/ext/standard/tests/array/array_chunk_variation2.phpt b/ext/standard/tests/array/array_chunk_variation2.phpt
deleted file mode 100644
index ea6468cd8b..0000000000
--- a/ext/standard/tests/array/array_chunk_variation2.phpt
+++ /dev/null
@@ -1,429 +0,0 @@
---TEST--
-Test array_chunk() function : usage variations - unexpected values for 'size' argument
---SKIPIF--
-<?php if (PHP_INT_SIZE != 8) die("skip this test is for 64-bit only");
---FILE--
-<?php
-/* Prototype : array array_chunk(array $array, int $size [, bool $preserve_keys])
- * Description: Split array into chunks
- : Chunks an array into size large chunks
- * Source code: ext/standard/array.c
-*/
-
-/*
-* Testing array_chunk() function with unexpected values for 'size' argument
-*/
-
-echo "*** Testing array_chunk() : usage variations ***\n";
-
-// input array
-$input = array(1, 2);
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-//array of values to iterate over
-$values = array (
-
- // float data
-/*1*/ 10.5,
- -10.5,
- 10.5e10,
- 10.6E-10,
- .5,
-
- // array data
-/*6*/ array(),
- array(0),
- array(1),
- array(1, 2),
- array('color' => 'red', 'item' => 'pen'),
-
- // null data
-/*11*/ NULL,
- null,
-
- // boolean data
-/*13*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*17*/ "",
- '',
-
- // string data
-/*19*/ "string",
- 'string',
-
- // object data
-/*21*/ new stdclass(),
-
- // undefined data
-/*22*/ @undefined_var,
-
- // unset data
-/*23*/ @unset_var
-
-);
-
-// loop through each element of the array for size
-$count = 1;
-foreach($values as $value){
- echo "\n-- Iteration $count --\n";
- var_dump( array_chunk($input, $value) );
- var_dump( array_chunk($input, $value, true) );
- var_dump( array_chunk($input, $value, false) );
- $count++;
-}
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing array_chunk() : usage variations ***
-
--- Iteration 1 --
-array(1) {
- [0]=>
- array(2) {
- [0]=>
- int(1)
- [1]=>
- int(2)
- }
-}
-array(1) {
- [0]=>
- array(2) {
- [0]=>
- int(1)
- [1]=>
- int(2)
- }
-}
-array(1) {
- [0]=>
- array(2) {
- [0]=>
- int(1)
- [1]=>
- int(2)
- }
-}
-
--- Iteration 2 --
-
-Warning: array_chunk(): Size parameter expected to be greater than 0 in %s on line %d
-NULL
-
-Warning: array_chunk(): Size parameter expected to be greater than 0 in %s on line %d
-NULL
-
-Warning: array_chunk(): Size parameter expected to be greater than 0 in %s on line %d
-NULL
-
--- Iteration 3 --
-array(1) {
- [0]=>
- array(2) {
- [0]=>
- int(1)
- [1]=>
- int(2)
- }
-}
-array(1) {
- [0]=>
- array(2) {
- [0]=>
- int(1)
- [1]=>
- int(2)
- }
-}
-array(1) {
- [0]=>
- array(2) {
- [0]=>
- int(1)
- [1]=>
- int(2)
- }
-}
-
--- Iteration 4 --
-
-Warning: array_chunk(): Size parameter expected to be greater than 0 in %s on line %d
-NULL
-
-Warning: array_chunk(): Size parameter expected to be greater than 0 in %s on line %d
-NULL
-
-Warning: array_chunk(): Size parameter expected to be greater than 0 in %s on line %d
-NULL
-
--- Iteration 5 --
-
-Warning: array_chunk(): Size parameter expected to be greater than 0 in %s on line %d
-NULL
-
-Warning: array_chunk(): Size parameter expected to be greater than 0 in %s on line %d
-NULL
-
-Warning: array_chunk(): Size parameter expected to be greater than 0 in %s on line %d
-NULL
-
--- Iteration 6 --
-
-Warning: array_chunk() expects parameter 2 to be int, array given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 2 to be int, array given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 2 to be int, array given in %s on line %d
-NULL
-
--- Iteration 7 --
-
-Warning: array_chunk() expects parameter 2 to be int, array given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 2 to be int, array given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 2 to be int, array given in %s on line %d
-NULL
-
--- Iteration 8 --
-
-Warning: array_chunk() expects parameter 2 to be int, array given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 2 to be int, array given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 2 to be int, array given in %s on line %d
-NULL
-
--- Iteration 9 --
-
-Warning: array_chunk() expects parameter 2 to be int, array given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 2 to be int, array given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 2 to be int, array given in %s on line %d
-NULL
-
--- Iteration 10 --
-
-Warning: array_chunk() expects parameter 2 to be int, array given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 2 to be int, array given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 2 to be int, array given in %s on line %d
-NULL
-
--- Iteration 11 --
-
-Warning: array_chunk(): Size parameter expected to be greater than 0 in %s on line %d
-NULL
-
-Warning: array_chunk(): Size parameter expected to be greater than 0 in %s on line %d
-NULL
-
-Warning: array_chunk(): Size parameter expected to be greater than 0 in %s on line %d
-NULL
-
--- Iteration 12 --
-
-Warning: array_chunk(): Size parameter expected to be greater than 0 in %s on line %d
-NULL
-
-Warning: array_chunk(): Size parameter expected to be greater than 0 in %s on line %d
-NULL
-
-Warning: array_chunk(): Size parameter expected to be greater than 0 in %s on line %d
-NULL
-
--- Iteration 13 --
-array(2) {
- [0]=>
- array(1) {
- [0]=>
- int(1)
- }
- [1]=>
- array(1) {
- [0]=>
- int(2)
- }
-}
-array(2) {
- [0]=>
- array(1) {
- [0]=>
- int(1)
- }
- [1]=>
- array(1) {
- [1]=>
- int(2)
- }
-}
-array(2) {
- [0]=>
- array(1) {
- [0]=>
- int(1)
- }
- [1]=>
- array(1) {
- [0]=>
- int(2)
- }
-}
-
--- Iteration 14 --
-
-Warning: array_chunk(): Size parameter expected to be greater than 0 in %s on line %d
-NULL
-
-Warning: array_chunk(): Size parameter expected to be greater than 0 in %s on line %d
-NULL
-
-Warning: array_chunk(): Size parameter expected to be greater than 0 in %s on line %d
-NULL
-
--- Iteration 15 --
-array(2) {
- [0]=>
- array(1) {
- [0]=>
- int(1)
- }
- [1]=>
- array(1) {
- [0]=>
- int(2)
- }
-}
-array(2) {
- [0]=>
- array(1) {
- [0]=>
- int(1)
- }
- [1]=>
- array(1) {
- [1]=>
- int(2)
- }
-}
-array(2) {
- [0]=>
- array(1) {
- [0]=>
- int(1)
- }
- [1]=>
- array(1) {
- [0]=>
- int(2)
- }
-}
-
--- Iteration 16 --
-
-Warning: array_chunk(): Size parameter expected to be greater than 0 in %s on line %d
-NULL
-
-Warning: array_chunk(): Size parameter expected to be greater than 0 in %s on line %d
-NULL
-
-Warning: array_chunk(): Size parameter expected to be greater than 0 in %s on line %d
-NULL
-
--- Iteration 17 --
-
-Warning: array_chunk() expects parameter 2 to be int, string given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 2 to be int, string given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 2 to be int, string given in %s on line %d
-NULL
-
--- Iteration 18 --
-
-Warning: array_chunk() expects parameter 2 to be int, string given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 2 to be int, string given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 2 to be int, string given in %s on line %d
-NULL
-
--- Iteration 19 --
-
-Warning: array_chunk() expects parameter 2 to be int, string given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 2 to be int, string given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 2 to be int, string given in %s on line %d
-NULL
-
--- Iteration 20 --
-
-Warning: array_chunk() expects parameter 2 to be int, string given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 2 to be int, string given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 2 to be int, string given in %s on line %d
-NULL
-
--- Iteration 21 --
-
-Warning: array_chunk() expects parameter 2 to be int, object given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 2 to be int, object given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 2 to be int, object given in %s on line %d
-NULL
-
--- Iteration 22 --
-
-Warning: array_chunk() expects parameter 2 to be int, string given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 2 to be int, string given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 2 to be int, string given in %s on line %d
-NULL
-
--- Iteration 23 --
-
-Warning: array_chunk() expects parameter 2 to be int, string given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 2 to be int, string given in %s on line %d
-NULL
-
-Warning: array_chunk() expects parameter 2 to be int, string given in %s on line %d
-NULL
-Done
diff --git a/ext/standard/tests/array/array_chunk_variation3.phpt b/ext/standard/tests/array/array_chunk_variation3.phpt
deleted file mode 100644
index 6492410c66..0000000000
--- a/ext/standard/tests/array/array_chunk_variation3.phpt
+++ /dev/null
@@ -1,268 +0,0 @@
---TEST--
-Test array_chunk() function : usage variations - unexpected values for 'preserve_keys'
---FILE--
-<?php
-/* Prototype : array array_chunk(array $array, int $size [, bool $preserve_keys])
- * Description: Split array into chunks
- * Source code: ext/standard/array.c
-*/
-
-/*
-* Testing array_chunk() function with unexpected values for 'preserve_keys'
-*/
-
-echo "*** Testing array_chunk() : usage variations ***\n";
-
-// input array
-$input = array(1, 2);
-$size = 10;
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-//array of values to iterate over
-$values = array(
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 10.5e10,
- 10.6E-10,
- .5,
-
- // null data
-/*10*/ NULL,
- null,
-
- // empty data
-/*12*/ "",
- '',
-
- // string data
-/*14*/ "string",
- 'string',
-
- // object data
-/*16*/ new stdclass(),
-
- // undefined data
-/*17*/ @undefined_var,
-
- // unset data
-/*18*/ @unset_var
-
-);
-
-$count = 1;
-
-// loop through each element of the array for preserve_keys
-foreach($values as $value) {
- echo "\n-- Iteration $count --\n";
- var_dump( array_chunk($input, $size, $value) );
- $count++;
-}
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing array_chunk() : usage variations ***
-
--- Iteration 1 --
-array(1) {
- [0]=>
- array(2) {
- [0]=>
- int(1)
- [1]=>
- int(2)
- }
-}
-
--- Iteration 2 --
-array(1) {
- [0]=>
- array(2) {
- [0]=>
- int(1)
- [1]=>
- int(2)
- }
-}
-
--- Iteration 3 --
-array(1) {
- [0]=>
- array(2) {
- [0]=>
- int(1)
- [1]=>
- int(2)
- }
-}
-
--- Iteration 4 --
-array(1) {
- [0]=>
- array(2) {
- [0]=>
- int(1)
- [1]=>
- int(2)
- }
-}
-
--- Iteration 5 --
-array(1) {
- [0]=>
- array(2) {
- [0]=>
- int(1)
- [1]=>
- int(2)
- }
-}
-
--- Iteration 6 --
-array(1) {
- [0]=>
- array(2) {
- [0]=>
- int(1)
- [1]=>
- int(2)
- }
-}
-
--- Iteration 7 --
-array(1) {
- [0]=>
- array(2) {
- [0]=>
- int(1)
- [1]=>
- int(2)
- }
-}
-
--- Iteration 8 --
-array(1) {
- [0]=>
- array(2) {
- [0]=>
- int(1)
- [1]=>
- int(2)
- }
-}
-
--- Iteration 9 --
-array(1) {
- [0]=>
- array(2) {
- [0]=>
- int(1)
- [1]=>
- int(2)
- }
-}
-
--- Iteration 10 --
-array(1) {
- [0]=>
- array(2) {
- [0]=>
- int(1)
- [1]=>
- int(2)
- }
-}
-
--- Iteration 11 --
-array(1) {
- [0]=>
- array(2) {
- [0]=>
- int(1)
- [1]=>
- int(2)
- }
-}
-
--- Iteration 12 --
-array(1) {
- [0]=>
- array(2) {
- [0]=>
- int(1)
- [1]=>
- int(2)
- }
-}
-
--- Iteration 13 --
-array(1) {
- [0]=>
- array(2) {
- [0]=>
- int(1)
- [1]=>
- int(2)
- }
-}
-
--- Iteration 14 --
-array(1) {
- [0]=>
- array(2) {
- [0]=>
- int(1)
- [1]=>
- int(2)
- }
-}
-
--- Iteration 15 --
-array(1) {
- [0]=>
- array(2) {
- [0]=>
- int(1)
- [1]=>
- int(2)
- }
-}
-
--- Iteration 16 --
-
-Warning: array_chunk() expects parameter 3 to be bool, object given in %s on line %d
-NULL
-
--- Iteration 17 --
-array(1) {
- [0]=>
- array(2) {
- [0]=>
- int(1)
- [1]=>
- int(2)
- }
-}
-
--- Iteration 18 --
-array(1) {
- [0]=>
- array(2) {
- [0]=>
- int(1)
- [1]=>
- int(2)
- }
-}
-Done
diff --git a/ext/standard/tests/array/array_combine_variation1.phpt b/ext/standard/tests/array/array_combine_variation1.phpt
deleted file mode 100644
index f9978f5476..0000000000
--- a/ext/standard/tests/array/array_combine_variation1.phpt
+++ /dev/null
@@ -1,198 +0,0 @@
---TEST--
-Test array_combine() function : usage variations - unexpected values for 'keys' argument
---FILE--
-<?php
-/* Prototype : array array_combine(array $keys, array $values)
- * Description: Creates an array by using the elements of the first parameter as keys
- * and the elements of the second as the corresponding values
- * Source code: ext/standard/array.c
-*/
-
-/*
-* Testing array_combine() function by passing values to $keys argument other than arrays
-* and see that function emits proper warning messages wherever expected.
-* The $values argument passed is a fixed array.
-*/
-
-echo "*** Testing array_combine() : Passing non-array values to \$keys argument ***\n";
-
-// Initialise $values argument
-$values = array(1, 2);
-
-//get an unset variable
-$unset_var = 10;
-unset($unset_var);
-
-// get a class
-class classA
-{
- public function __toString() {
- return "Class A object";
- }
-}
-
-// heredoc string
-$heredoc = <<<EOT
-hello world
-EOT;
-
-// get a resource variable
-$fp = fopen(__FILE__, "r");
-
-// unexpected values to be passed to $keys argument
-$keys_passed = array(
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 12.3456789000e10,
- 12.3456789000E-10,
- .5,
-
- // null data
-/*10*/ NULL,
- null,
-
- // boolean data
-/*12*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*16*/ "",
- '',
-
- // string data
-/*18*/ "string",
- 'string',
- $heredoc,
-
- // object data
-/*21*/ new classA(),
-
- // undefined data
-/*22*/ @$undefined_var,
-
- // unset data
-/*23*/ @$unset_var,
-
- // resource variable
-/*24*/ $fp
-);
-
-// loop through each element within $keys_passed to check the behavior of array_combine()
-$iterator = 1;
-foreach($keys_passed as $keys) {
- echo "-- Iteration $iterator --\n";
- var_dump( array_combine($keys,$values) );
- $iterator++;
-};
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing array_combine() : Passing non-array values to $keys argument ***
--- Iteration 1 --
-
-Warning: array_combine() expects parameter 1 to be array, int given in %s on line %d
-NULL
--- Iteration 2 --
-
-Warning: array_combine() expects parameter 1 to be array, int given in %s on line %d
-NULL
--- Iteration 3 --
-
-Warning: array_combine() expects parameter 1 to be array, int given in %s on line %d
-NULL
--- Iteration 4 --
-
-Warning: array_combine() expects parameter 1 to be array, int given in %s on line %d
-NULL
--- Iteration 5 --
-
-Warning: array_combine() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 6 --
-
-Warning: array_combine() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 7 --
-
-Warning: array_combine() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 8 --
-
-Warning: array_combine() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 9 --
-
-Warning: array_combine() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 10 --
-
-Warning: array_combine() expects parameter 1 to be array, null given in %s on line %d
-NULL
--- Iteration 11 --
-
-Warning: array_combine() expects parameter 1 to be array, null given in %s on line %d
-NULL
--- Iteration 12 --
-
-Warning: array_combine() expects parameter 1 to be array, bool given in %s on line %d
-NULL
--- Iteration 13 --
-
-Warning: array_combine() expects parameter 1 to be array, bool given in %s on line %d
-NULL
--- Iteration 14 --
-
-Warning: array_combine() expects parameter 1 to be array, bool given in %s on line %d
-NULL
--- Iteration 15 --
-
-Warning: array_combine() expects parameter 1 to be array, bool given in %s on line %d
-NULL
--- Iteration 16 --
-
-Warning: array_combine() expects parameter 1 to be array, string given in %s on line %d
-NULL
--- Iteration 17 --
-
-Warning: array_combine() expects parameter 1 to be array, string given in %s on line %d
-NULL
--- Iteration 18 --
-
-Warning: array_combine() expects parameter 1 to be array, string given in %s on line %d
-NULL
--- Iteration 19 --
-
-Warning: array_combine() expects parameter 1 to be array, string given in %s on line %d
-NULL
--- Iteration 20 --
-
-Warning: array_combine() expects parameter 1 to be array, string given in %s on line %d
-NULL
--- Iteration 21 --
-
-Warning: array_combine() expects parameter 1 to be array, object given in %s on line %d
-NULL
--- Iteration 22 --
-
-Warning: array_combine() expects parameter 1 to be array, null given in %s on line %d
-NULL
--- Iteration 23 --
-
-Warning: array_combine() expects parameter 1 to be array, null given in %s on line %d
-NULL
--- Iteration 24 --
-
-Warning: array_combine() expects parameter 1 to be array, resource given in %s on line %d
-NULL
-Done
diff --git a/ext/standard/tests/array/array_combine_variation2.phpt b/ext/standard/tests/array/array_combine_variation2.phpt
deleted file mode 100644
index 2d888df694..0000000000
--- a/ext/standard/tests/array/array_combine_variation2.phpt
+++ /dev/null
@@ -1,198 +0,0 @@
---TEST--
-Test array_combine() function : usage variations - unexpected values for 'values' argument
---FILE--
-<?php
-/* Prototype : array array_combine(array $keys, array $values)
- * Description: Creates an array by using the elements of the first parameter as keys
- * and the elements of the second as the corresponding values
- * Source code: ext/standard/array.c
-*/
-
-/*
-* Testing array_combine() function by passing values to $values argument other than arrays
-* and see that function emits proper warning messages wherever expected.
-* The $keys argument passed is a fixed array.
-*/
-
-echo "*** Testing array_combine() : Passing non-array values to \$values argument ***\n";
-
-// Initialize $keys array
-$keys = array(1, 2);
-
-//get an unset variable
-$unset_var = 10;
-unset($unset_var);
-
-// get a class
-class classA
-{
- public function __toString() {
- return "Class A object";
- }
-}
-
-// heredoc string
-$heredoc = <<<EOT
-hello world
-EOT;
-
-// get a resource variable
-$fp = fopen(__FILE__, "r");
-
-// unexpected values to be passed to $values argument
-$values_passed = array(
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 12.3456789000e10,
- 12.3456789000E-10,
- .5,
-
- // null data
-/*10*/ NULL,
- null,
-
- // boolean data
-/*12*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*16*/ "",
- '',
-
- // string data
-/*18*/ "string",
- 'string',
- $heredoc,
-
- // object data
-/*21*/ new classA(),
-
- // undefined data
-/*22*/ @$undefined_var,
-
- // unset data
-/*23*/ @$unset_var,
-
- // resource variable
-/*24*/ $fp
-);
-
-// loop through each element within $values_passed to check the behavior of array_combine()
-$iterator = 1;
-foreach($values_passed as $values) {
- echo "-- Iteration $iterator --\n";
- var_dump( array_combine($keys,$values) );
- $iterator++;
-};
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing array_combine() : Passing non-array values to $values argument ***
--- Iteration 1 --
-
-Warning: array_combine() expects parameter 2 to be array, int given in %s on line %d
-NULL
--- Iteration 2 --
-
-Warning: array_combine() expects parameter 2 to be array, int given in %s on line %d
-NULL
--- Iteration 3 --
-
-Warning: array_combine() expects parameter 2 to be array, int given in %s on line %d
-NULL
--- Iteration 4 --
-
-Warning: array_combine() expects parameter 2 to be array, int given in %s on line %d
-NULL
--- Iteration 5 --
-
-Warning: array_combine() expects parameter 2 to be array, float given in %s on line %d
-NULL
--- Iteration 6 --
-
-Warning: array_combine() expects parameter 2 to be array, float given in %s on line %d
-NULL
--- Iteration 7 --
-
-Warning: array_combine() expects parameter 2 to be array, float given in %s on line %d
-NULL
--- Iteration 8 --
-
-Warning: array_combine() expects parameter 2 to be array, float given in %s on line %d
-NULL
--- Iteration 9 --
-
-Warning: array_combine() expects parameter 2 to be array, float given in %s on line %d
-NULL
--- Iteration 10 --
-
-Warning: array_combine() expects parameter 2 to be array, null given in %s on line %d
-NULL
--- Iteration 11 --
-
-Warning: array_combine() expects parameter 2 to be array, null given in %s on line %d
-NULL
--- Iteration 12 --
-
-Warning: array_combine() expects parameter 2 to be array, bool given in %s on line %d
-NULL
--- Iteration 13 --
-
-Warning: array_combine() expects parameter 2 to be array, bool given in %s on line %d
-NULL
--- Iteration 14 --
-
-Warning: array_combine() expects parameter 2 to be array, bool given in %s on line %d
-NULL
--- Iteration 15 --
-
-Warning: array_combine() expects parameter 2 to be array, bool given in %s on line %d
-NULL
--- Iteration 16 --
-
-Warning: array_combine() expects parameter 2 to be array, string given in %s on line %d
-NULL
--- Iteration 17 --
-
-Warning: array_combine() expects parameter 2 to be array, string given in %s on line %d
-NULL
--- Iteration 18 --
-
-Warning: array_combine() expects parameter 2 to be array, string given in %s on line %d
-NULL
--- Iteration 19 --
-
-Warning: array_combine() expects parameter 2 to be array, string given in %s on line %d
-NULL
--- Iteration 20 --
-
-Warning: array_combine() expects parameter 2 to be array, string given in %s on line %d
-NULL
--- Iteration 21 --
-
-Warning: array_combine() expects parameter 2 to be array, object given in %s on line %d
-NULL
--- Iteration 22 --
-
-Warning: array_combine() expects parameter 2 to be array, null given in %s on line %d
-NULL
--- Iteration 23 --
-
-Warning: array_combine() expects parameter 2 to be array, null given in %s on line %d
-NULL
--- Iteration 24 --
-
-Warning: array_combine() expects parameter 2 to be array, resource given in %s on line %d
-NULL
-Done
diff --git a/ext/standard/tests/array/array_fill_variation1.phpt b/ext/standard/tests/array/array_fill_variation1.phpt
deleted file mode 100644
index f3bdef1b61..0000000000
--- a/ext/standard/tests/array/array_fill_variation1.phpt
+++ /dev/null
@@ -1,244 +0,0 @@
---TEST--
-Test array_fill() function : usage variations - unexpected values for 'start_key' argument
---SKIPIF--
-<?php
-if (PHP_INT_SIZE != 4) die("skip this test is for 32bit platform only");
-?>
---FILE--
-<?php
-/* Prototype : proto array array_fill(int start_key, int num, mixed val)
- * Description: Create an array containing num elements starting with index start_key each initialized to val
- * Source code: ext/standard/array.c
- */
-
-/*
- * testing array_fill() by passing different unexpected value for 'start_key' argument
- */
-
-echo "*** Testing array_fill() : usage variations ***\n";
-
-// Initialise function arguments not being substituted
-$num = 2;
-$val = 100;
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-//get a resource variable
-$fp = fopen(__FILE__, "r");
-
-//define a class
-class test
-{
- var $t = 10;
- function __toString()
- {
- return "testObject";
- }
-}
-
-
-//array of different values for 'start_key' argument
-$values = array(
-
- // float values
- /* 1 */ 10.5,
- -10.5,
- 12.3456789000e10,
- 12.34567890006E-10,
- .5,
-
- // array values
- /* 6 */ array(),
- array(0),
- array(1),
- array(1, 2),
- array('color' => 'red', 'item' => 'pen'),
-
- // null values
- /* 11 */ NULL,
- null,
-
- // boolean values
- /* 13 */ true,
- false,
- TRUE,
- FALSE,
-
- // empty string
- /* 17 */ "",
- '',
-
- // string values
- /* 19 */ "string",
- 'string',
-
- // objects
- /* 21 */ new test(),
-
- // undefined variable
- @$undefined_var,
-
- // unset variable
- @$unset_var,
-
- // resource variable
- /* 24 */ $fp
-);
-
-// loop through each element of the array for start_key
-// check the working of array_fill()
-echo "--- Testing array_fill() with different values for 'start_key' arg ---\n";
-$counter = 1;
-for($index = 0; $index < count($values); $index ++)
-{
- echo "-- Iteration $counter --\n";
- $start_key = $values[$index];
-
- var_dump( array_fill($start_key,$num,$val) );
-
- $counter ++;
-}
-
-// close the resource used
-fclose($fp);
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing array_fill() : usage variations ***
---- Testing array_fill() with different values for 'start_key' arg ---
--- Iteration 1 --
-array(2) {
- [10]=>
- int(100)
- [11]=>
- int(100)
-}
--- Iteration 2 --
-array(2) {
- [-10]=>
- int(100)
- [0]=>
- int(100)
-}
--- Iteration 3 --
-
-Warning: array_fill() expects parameter 1 to be int, float given in %s%eext%estandard%etests%earray%earray_fill_variation1.php on line 92
-NULL
--- Iteration 4 --
-array(2) {
- [0]=>
- int(100)
- [1]=>
- int(100)
-}
--- Iteration 5 --
-array(2) {
- [0]=>
- int(100)
- [1]=>
- int(100)
-}
--- Iteration 6 --
-
-Warning: array_fill() expects parameter 1 to be int, array given in %sarray_fill_variation1.php on line %d
-NULL
--- Iteration 7 --
-
-Warning: array_fill() expects parameter 1 to be int, array given in %sarray_fill_variation1.php on line %d
-NULL
--- Iteration 8 --
-
-Warning: array_fill() expects parameter 1 to be int, array given in %sarray_fill_variation1.php on line %d
-NULL
--- Iteration 9 --
-
-Warning: array_fill() expects parameter 1 to be int, array given in %sarray_fill_variation1.php on line %d
-NULL
--- Iteration 10 --
-
-Warning: array_fill() expects parameter 1 to be int, array given in %sarray_fill_variation1.php on line %d
-NULL
--- Iteration 11 --
-array(2) {
- [0]=>
- int(100)
- [1]=>
- int(100)
-}
--- Iteration 12 --
-array(2) {
- [0]=>
- int(100)
- [1]=>
- int(100)
-}
--- Iteration 13 --
-array(2) {
- [1]=>
- int(100)
- [2]=>
- int(100)
-}
--- Iteration 14 --
-array(2) {
- [0]=>
- int(100)
- [1]=>
- int(100)
-}
--- Iteration 15 --
-array(2) {
- [1]=>
- int(100)
- [2]=>
- int(100)
-}
--- Iteration 16 --
-array(2) {
- [0]=>
- int(100)
- [1]=>
- int(100)
-}
--- Iteration 17 --
-
-Warning: array_fill() expects parameter 1 to be int, string given in %sarray_fill_variation1.php on line %d
-NULL
--- Iteration 18 --
-
-Warning: array_fill() expects parameter 1 to be int, string given in %sarray_fill_variation1.php on line %d
-NULL
--- Iteration 19 --
-
-Warning: array_fill() expects parameter 1 to be int, string given in %sarray_fill_variation1.php on line %d
-NULL
--- Iteration 20 --
-
-Warning: array_fill() expects parameter 1 to be int, string given in %sarray_fill_variation1.php on line %d
-NULL
--- Iteration 21 --
-
-Warning: array_fill() expects parameter 1 to be int, object given in %sarray_fill_variation1.php on line %d
-NULL
--- Iteration 22 --
-array(2) {
- [0]=>
- int(100)
- [1]=>
- int(100)
-}
--- Iteration 23 --
-array(2) {
- [0]=>
- int(100)
- [1]=>
- int(100)
-}
--- Iteration 24 --
-
-Warning: array_fill() expects parameter 1 to be int, resource given in %sarray_fill_variation1.php on line %d
-NULL
-Done
diff --git a/ext/standard/tests/array/array_fill_variation1_64bit.phpt b/ext/standard/tests/array/array_fill_variation1_64bit.phpt
deleted file mode 100644
index ba3a70c482..0000000000
--- a/ext/standard/tests/array/array_fill_variation1_64bit.phpt
+++ /dev/null
@@ -1,247 +0,0 @@
---TEST--
-Test array_fill() function : usage variations - unexpected values for 'start_key' argument
---SKIPIF--
-<?php
-if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only");
-?>
---FILE--
-<?php
-/* Prototype : proto array array_fill(int start_key, int num, mixed val)
- * Description: Create an array containing num elements starting with index start_key each initialized to val
- * Source code: ext/standard/array.c
- */
-
-/*
- * testing array_fill() by passing different unexpected value for 'start_key' argument
- */
-
-echo "*** Testing array_fill() : usage variations ***\n";
-
-// Initialise function arguments not being substituted
-$num = 2;
-$val = 100;
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-//get a resource variable
-$fp = fopen(__FILE__, "r");
-
-//define a class
-class test
-{
- var $t = 10;
- function __toString()
- {
- return "testObject";
- }
-}
-
-
-//array of different values for 'start_key' argument
-$values = array(
-
- // float values
- /* 1 */ 10.5,
- -10.5,
- 12.3456789000e10,
- 12.34567890006E-10,
- .5,
-
- // array values
- /* 6 */ array(),
- array(0),
- array(1),
- array(1, 2),
- array('color' => 'red', 'item' => 'pen'),
-
- // null values
- /* 11 */ NULL,
- null,
-
- // boolean values
- /* 13 */ true,
- false,
- TRUE,
- FALSE,
-
- // empty string
- /* 17 */ "",
- '',
-
- // string values
- /* 19 */ "string",
- 'string',
-
- // objects
- /* 21 */ new test(),
-
- // undefined variable
- @$undefined_var,
-
- // unset variable
- @$unset_var,
-
- // resource variable
- /* 24 */ $fp
-);
-
-// loop through each element of the array for start_key
-// check the working of array_fill()
-echo "--- Testing array_fill() with different values for 'start_key' arg ---\n";
-$counter = 1;
-for($index = 0; $index < count($values); $index ++)
-{
- echo "-- Iteration $counter --\n";
- $start_key = $values[$index];
-
- var_dump( array_fill($start_key,$num,$val) );
-
- $counter ++;
-}
-
-// close the resource used
-fclose($fp);
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing array_fill() : usage variations ***
---- Testing array_fill() with different values for 'start_key' arg ---
--- Iteration 1 --
-array(2) {
- [10]=>
- int(100)
- [11]=>
- int(100)
-}
--- Iteration 2 --
-array(2) {
- [-10]=>
- int(100)
- [0]=>
- int(100)
-}
--- Iteration 3 --
-array(2) {
- [123456789000]=>
- int(100)
- [123456789001]=>
- int(100)
-}
--- Iteration 4 --
-array(2) {
- [0]=>
- int(100)
- [1]=>
- int(100)
-}
--- Iteration 5 --
-array(2) {
- [0]=>
- int(100)
- [1]=>
- int(100)
-}
--- Iteration 6 --
-
-Warning: array_fill() expects parameter 1 to be int, array given in %s on line %d
-NULL
--- Iteration 7 --
-
-Warning: array_fill() expects parameter 1 to be int, array given in %s on line %d
-NULL
--- Iteration 8 --
-
-Warning: array_fill() expects parameter 1 to be int, array given in %s on line %d
-NULL
--- Iteration 9 --
-
-Warning: array_fill() expects parameter 1 to be int, array given in %s on line %d
-NULL
--- Iteration 10 --
-
-Warning: array_fill() expects parameter 1 to be int, array given in %s on line %d
-NULL
--- Iteration 11 --
-array(2) {
- [0]=>
- int(100)
- [1]=>
- int(100)
-}
--- Iteration 12 --
-array(2) {
- [0]=>
- int(100)
- [1]=>
- int(100)
-}
--- Iteration 13 --
-array(2) {
- [1]=>
- int(100)
- [2]=>
- int(100)
-}
--- Iteration 14 --
-array(2) {
- [0]=>
- int(100)
- [1]=>
- int(100)
-}
--- Iteration 15 --
-array(2) {
- [1]=>
- int(100)
- [2]=>
- int(100)
-}
--- Iteration 16 --
-array(2) {
- [0]=>
- int(100)
- [1]=>
- int(100)
-}
--- Iteration 17 --
-
-Warning: array_fill() expects parameter 1 to be int, string given in %s on line %d
-NULL
--- Iteration 18 --
-
-Warning: array_fill() expects parameter 1 to be int, string given in %s on line %d
-NULL
--- Iteration 19 --
-
-Warning: array_fill() expects parameter 1 to be int, string given in %s on line %d
-NULL
--- Iteration 20 --
-
-Warning: array_fill() expects parameter 1 to be int, string given in %s on line %d
-NULL
--- Iteration 21 --
-
-Warning: array_fill() expects parameter 1 to be int, object given in %s on line %d
-NULL
--- Iteration 22 --
-array(2) {
- [0]=>
- int(100)
- [1]=>
- int(100)
-}
--- Iteration 23 --
-array(2) {
- [0]=>
- int(100)
- [1]=>
- int(100)
-}
--- Iteration 24 --
-
-Warning: array_fill() expects parameter 1 to be int, resource given in %s on line %d
-NULL
-Done
diff --git a/ext/standard/tests/array/array_fill_variation2.phpt b/ext/standard/tests/array/array_fill_variation2.phpt
deleted file mode 100644
index 1209aea44d..0000000000
--- a/ext/standard/tests/array/array_fill_variation2.phpt
+++ /dev/null
@@ -1,198 +0,0 @@
---TEST--
-Test array_fill() function : usage variations - unexpected values for 'num' argument
---FILE--
-<?php
-/* Prototype : proto array array_fill(int start_key, int num, mixed val)
- * Description: Create an array containing num elements starting with index start_key each initialized to val
- * Source code: ext/standard/array.c
- */
-
-/*
- * testing array_fill() by passing different unexpected values for 'num' argument
- */
-
-echo "*** Testing array_fill() : usage variations ***\n";
-
-// Initialise function arguments not being substituted
-$start_key = 0;
-$val = 100;
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-//define a class
-class test
-{
- var $t = 10;
- function __toString()
- {
- return "testObject";
- }
-}
-
-
-//array of different values for 'num' argument
-$values = array(
-
- // float values
- /* 1 */ 2.5,
- -2.5,
- 0.5e1,
- 0.5E-1,
- .5,
-
- // array values
- /* 6 */ array(),
- array(0),
- array(1),
- array(1, 2),
- array('color' => 'red', 'item' => 'pen'),
-
- // null values
- /* 11 */ NULL,
- null,
-
- // boolean values
- /* 13 */ true,
- false,
- TRUE,
- FALSE,
-
- // empty string
- /* 17 */ "",
- '',
-
- // string values
- /* 19 */ "string",
- 'string',
-
- // objects
- /* 21 */ new test(),
-
- // undefined variable
- @$undefined_var,
-
- // unset variable
- /* 24 */ @$unset_var,
-
-);
-
-// loop through each element of the array for num
-// check the working of array_fill
-echo "--- Testing array_fill() with different values for 'num' arg ---\n";
-$counter = 1;
-for($index = 0; $index < count($values); $index ++)
-{
- echo "-- Iteration $counter --\n";
- $num = $values[$index];
-
- var_dump( array_fill($start_key,$num,$val) );
-
- $counter ++;
-}
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing array_fill() : usage variations ***
---- Testing array_fill() with different values for 'num' arg ---
--- Iteration 1 --
-array(2) {
- [0]=>
- int(100)
- [1]=>
- int(100)
-}
--- Iteration 2 --
-
-Warning: array_fill(): Number of elements can't be negative in %s on line %d
-bool(false)
--- Iteration 3 --
-array(5) {
- [0]=>
- int(100)
- [1]=>
- int(100)
- [2]=>
- int(100)
- [3]=>
- int(100)
- [4]=>
- int(100)
-}
--- Iteration 4 --
-array(0) {
-}
--- Iteration 5 --
-array(0) {
-}
--- Iteration 6 --
-
-Warning: array_fill() expects parameter 2 to be int, array given in %s on line %d
-NULL
--- Iteration 7 --
-
-Warning: array_fill() expects parameter 2 to be int, array given in %s on line %d
-NULL
--- Iteration 8 --
-
-Warning: array_fill() expects parameter 2 to be int, array given in %s on line %d
-NULL
--- Iteration 9 --
-
-Warning: array_fill() expects parameter 2 to be int, array given in %s on line %d
-NULL
--- Iteration 10 --
-
-Warning: array_fill() expects parameter 2 to be int, array given in %s on line %d
-NULL
--- Iteration 11 --
-array(0) {
-}
--- Iteration 12 --
-array(0) {
-}
--- Iteration 13 --
-array(1) {
- [0]=>
- int(100)
-}
--- Iteration 14 --
-array(0) {
-}
--- Iteration 15 --
-array(1) {
- [0]=>
- int(100)
-}
--- Iteration 16 --
-array(0) {
-}
--- Iteration 17 --
-
-Warning: array_fill() expects parameter 2 to be int, string given in %s on line %d
-NULL
--- Iteration 18 --
-
-Warning: array_fill() expects parameter 2 to be int, string given in %s on line %d
-NULL
--- Iteration 19 --
-
-Warning: array_fill() expects parameter 2 to be int, string given in %s on line %d
-NULL
--- Iteration 20 --
-
-Warning: array_fill() expects parameter 2 to be int, string given in %s on line %d
-NULL
--- Iteration 21 --
-
-Warning: array_fill() expects parameter 2 to be int, object given in %s on line %d
-NULL
--- Iteration 22 --
-array(0) {
-}
--- Iteration 23 --
-array(0) {
-}
-Done
diff --git a/ext/standard/tests/array/array_filter_variation1.phpt b/ext/standard/tests/array/array_filter_variation1.phpt
deleted file mode 100644
index f75b03cbed..0000000000
--- a/ext/standard/tests/array/array_filter_variation1.phpt
+++ /dev/null
@@ -1,195 +0,0 @@
---TEST--
-Test array_filter() function : usage variations - Unexpected values for 'input' argument
---FILE--
-<?php
-/* Prototype : array array_filter(array $input [, callback $callback])
- * Description: Filters elements from the array via the callback.
- * Source code: ext/standard/array.c
-*/
-
-/* Passing different scalar and nonscalar values for 'input' argument
-*/
-echo "*** Testing array_filter() : usage variations - unexpected values for 'input'***\n";
-
-/* Callback function
- * Prototype : bool always_true(array $input)
- * Parameters : array for which each elements needs to be used in function
- * Return value : Returns true for each element
- * Discription : function applied to each element of the passed array and returns true
- */
-function always_true($input)
-{
- return true;
-}
-
-
-// get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// class definition for object variable
-class MyClass
-{
- public function __toString()
- {
- return "object";
- }
-}
-
-// resource variable
-$fp = fopen(__FILE__, 'r');
-
-// different values for 'input' argument
-$input_values = array(
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 12.3456789000e10,
- 12.3456789000E-10,
- .5,
-
-
- // null data
-/*10*/ NULL,
- null,
-
- // boolean data
-/*12*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*16*/ "",
- '',
-
- // string data
-/*18*/ "string",
- 'string',
-
- // object data
-/*20*/ new MyClass(),
-
- // resource data
- $fp,
-
- // undefined data
- @$undefined_var,
-
- // unset data
-/*23*/ @$unset_var,
-);
-
-// loop through each element of the array for input
-for($count = 0; $count < count($input_values); $count++) {
- echo "-- Iteration ".($count + 1)." --\n";
- var_dump( array_filter($input_values[$count],"always_true") );
-};
-
-// closing resource
-fclose($fp);
-
-echo "Done"
-?>
---EXPECTF--
-*** Testing array_filter() : usage variations - unexpected values for 'input'***
--- Iteration 1 --
-
-Warning: array_filter() expects parameter 1 to be array, int given in %s on line %d
-NULL
--- Iteration 2 --
-
-Warning: array_filter() expects parameter 1 to be array, int given in %s on line %d
-NULL
--- Iteration 3 --
-
-Warning: array_filter() expects parameter 1 to be array, int given in %s on line %d
-NULL
--- Iteration 4 --
-
-Warning: array_filter() expects parameter 1 to be array, int given in %s on line %d
-NULL
--- Iteration 5 --
-
-Warning: array_filter() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 6 --
-
-Warning: array_filter() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 7 --
-
-Warning: array_filter() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 8 --
-
-Warning: array_filter() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 9 --
-
-Warning: array_filter() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 10 --
-
-Warning: array_filter() expects parameter 1 to be array, null given in %s on line %d
-NULL
--- Iteration 11 --
-
-Warning: array_filter() expects parameter 1 to be array, null given in %s on line %d
-NULL
--- Iteration 12 --
-
-Warning: array_filter() expects parameter 1 to be array, bool given in %s on line %d
-NULL
--- Iteration 13 --
-
-Warning: array_filter() expects parameter 1 to be array, bool given in %s on line %d
-NULL
--- Iteration 14 --
-
-Warning: array_filter() expects parameter 1 to be array, bool given in %s on line %d
-NULL
--- Iteration 15 --
-
-Warning: array_filter() expects parameter 1 to be array, bool given in %s on line %d
-NULL
--- Iteration 16 --
-
-Warning: array_filter() expects parameter 1 to be array, string given in %s on line %d
-NULL
--- Iteration 17 --
-
-Warning: array_filter() expects parameter 1 to be array, string given in %s on line %d
-NULL
--- Iteration 18 --
-
-Warning: array_filter() expects parameter 1 to be array, string given in %s on line %d
-NULL
--- Iteration 19 --
-
-Warning: array_filter() expects parameter 1 to be array, string given in %s on line %d
-NULL
--- Iteration 20 --
-
-Warning: array_filter() expects parameter 1 to be array, object given in %s on line %d
-NULL
--- Iteration 21 --
-
-Warning: array_filter() expects parameter 1 to be array, resource given in %s on line %d
-NULL
--- Iteration 22 --
-
-Warning: array_filter() expects parameter 1 to be array, null given in %s on line %d
-NULL
--- Iteration 23 --
-
-Warning: array_filter() expects parameter 1 to be array, null given in %s on line %d
-NULL
-Done
diff --git a/ext/standard/tests/array/array_filter_variation2.phpt b/ext/standard/tests/array/array_filter_variation2.phpt
deleted file mode 100644
index d47761f470..0000000000
--- a/ext/standard/tests/array/array_filter_variation2.phpt
+++ /dev/null
@@ -1,184 +0,0 @@
---TEST--
-Test array_filter() function : usage variations - Unexpected values for 'callback' function argument
---FILE--
-<?php
-/* Prototype : array array_filter(array $input [, callback $callback])
- * Description: Filters elements from the array via the callback.
- * Source code: ext/standard/array.c
-*/
-
-/* Passing different scalar and nonscalar values in place of 'callback' argument
-*/
-echo "*** Testing array_filter() : usage variations - unexpected values for 'callback' function***\n";
-
-// Initialise variables
-$input = array('value1', 'value2', 'value3', 'value4');
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// class definition for object variable
-class MyClass
-{
- public function __toString()
- {
- return 'object';
- }
-}
-
-// resource variable
-$fp = fopen(__FILE__, 'r');
-
-// different scalar and nonscalar values in place of callback function
-$values = array(
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 12.3456789000e10,
- 12.3456789000E-10,
- .5,
-
- // array data
-/*10*/ array(),
- array(0),
- array(1),
- array(1, 2),
- array('color' => 'red', 'item' => 'pen'),
-
- // null data
-/*15*/ NULL,
- null,
-
- // boolean data
-/*17*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*21*/ "",
- '',
-
- // string data
-/*23*/ "string",
- 'string',
-
- // object data
-/*25*/ new MyClass(),
-
- // resource data
- $fp,
-
- // undefined data
- @$undefined_var,
-
- // unset data
-/*28*/ @$unset_var,
-);
-
-// loop through each element of the 'values' for callback
-for($count = 0; $count < count($values); $count++) {
- echo "-- Iteration ".($count + 1)." --";
- var_dump( array_filter($input, $values[$count]) );
-};
-
-// closing resource
-fclose($fp);
-
-echo "Done"
-?>
---EXPECTF--
-*** Testing array_filter() : usage variations - unexpected values for 'callback' function***
--- Iteration 1 --
-Warning: array_filter() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 2 --
-Warning: array_filter() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 3 --
-Warning: array_filter() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 4 --
-Warning: array_filter() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 5 --
-Warning: array_filter() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 6 --
-Warning: array_filter() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 7 --
-Warning: array_filter() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 8 --
-Warning: array_filter() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 9 --
-Warning: array_filter() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 10 --
-Warning: array_filter() expects parameter 2 to be a valid callback, array must have exactly two members in %s on line %d
-NULL
--- Iteration 11 --
-Warning: array_filter() expects parameter 2 to be a valid callback, array must have exactly two members in %s on line %d
-NULL
--- Iteration 12 --
-Warning: array_filter() expects parameter 2 to be a valid callback, array must have exactly two members in %s on line %d
-NULL
--- Iteration 13 --
-Warning: array_filter() expects parameter 2 to be a valid callback, first array member is not a valid class name or object in %s on line %d
-NULL
--- Iteration 14 --
-Warning: array_filter() expects parameter 2 to be a valid callback, first array member is not a valid class name or object in %s on line %d
-NULL
--- Iteration 15 --
-Warning: array_filter() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 16 --
-Warning: array_filter() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 17 --
-Warning: array_filter() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 18 --
-Warning: array_filter() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 19 --
-Warning: array_filter() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 20 --
-Warning: array_filter() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 21 --
-Warning: array_filter() expects parameter 2 to be a valid callback, function '' not found or invalid function name in %s on line %d
-NULL
--- Iteration 22 --
-Warning: array_filter() expects parameter 2 to be a valid callback, function '' not found or invalid function name in %s on line %d
-NULL
--- Iteration 23 --
-Warning: array_filter() expects parameter 2 to be a valid callback, function 'string' not found or invalid function name in %s on line %d
-NULL
--- Iteration 24 --
-Warning: array_filter() expects parameter 2 to be a valid callback, function 'string' not found or invalid function name in %s on line %d
-NULL
--- Iteration 25 --
-Warning: array_filter() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 26 --
-Warning: array_filter() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 27 --
-Warning: array_filter() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 28 --
-Warning: array_filter() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-Done
diff --git a/ext/standard/tests/array/array_flip_variation1.phpt b/ext/standard/tests/array/array_flip_variation1.phpt
deleted file mode 100644
index 98aa459362..0000000000
--- a/ext/standard/tests/array/array_flip_variation1.phpt
+++ /dev/null
@@ -1,179 +0,0 @@
---TEST--
-Test array_flip() function : usage variations - unexpected values for 'input' argument
---FILE--
-<?php
-/* Prototype : array array_flip(array $input)
- * Description: Return array with key <-> value flipped
- * Source code: ext/standard/array.c
-*/
-
-echo "*** Testing array_flip() : usage variations - unexpected values for 'input' ***\n";
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-//class definition for object variable
-class MyClass
-{
- public function __toString()
- {
- return 'object';
- }
-}
-
-//resource variable
-$fp = fopen(__FILE__,'r');
-
-//array of values for 'input' argument
-$values = array(
- // int data
- /*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
- /*5*/ 10.5,
- -10.5,
- 10.5e10,
- 10.6E-10,
- .5,
-
- // null data
- /*10*/ NULL,
- null,
-
- // boolean data
- /*12*/ true,
- false,
- TRUE,
- /*15*/ FALSE,
-
- // empty data
- "",
- '',
-
- // string data
- "string",
- 'string',
-
- // object data
- /*20*/ new MyClass(),
-
- // undefined data
- @$undefined_var,
-
- // unset data
- @$unset_var,
-
- //resource data
- /*23*/ $fp
-);
-
-// loop through each element of $values for 'input' argument
-for($count = 0; $count < count($values); $count++) {
- echo "-- Iteration ".($count + 1). " --\n";
- var_dump( array_flip($values[$count]) );
-};
-
-//closing resource
-fclose($fp);
-
-echo "Done"
-?>
---EXPECTF--
-*** Testing array_flip() : usage variations - unexpected values for 'input' ***
--- Iteration 1 --
-
-Warning: array_flip() expects parameter 1 to be array, int given in %s on line %d
-NULL
--- Iteration 2 --
-
-Warning: array_flip() expects parameter 1 to be array, int given in %s on line %d
-NULL
--- Iteration 3 --
-
-Warning: array_flip() expects parameter 1 to be array, int given in %s on line %d
-NULL
--- Iteration 4 --
-
-Warning: array_flip() expects parameter 1 to be array, int given in %s on line %d
-NULL
--- Iteration 5 --
-
-Warning: array_flip() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 6 --
-
-Warning: array_flip() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 7 --
-
-Warning: array_flip() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 8 --
-
-Warning: array_flip() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 9 --
-
-Warning: array_flip() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 10 --
-
-Warning: array_flip() expects parameter 1 to be array, null given in %s on line %d
-NULL
--- Iteration 11 --
-
-Warning: array_flip() expects parameter 1 to be array, null given in %s on line %d
-NULL
--- Iteration 12 --
-
-Warning: array_flip() expects parameter 1 to be array, bool given in %s on line %d
-NULL
--- Iteration 13 --
-
-Warning: array_flip() expects parameter 1 to be array, bool given in %s on line %d
-NULL
--- Iteration 14 --
-
-Warning: array_flip() expects parameter 1 to be array, bool given in %s on line %d
-NULL
--- Iteration 15 --
-
-Warning: array_flip() expects parameter 1 to be array, bool given in %s on line %d
-NULL
--- Iteration 16 --
-
-Warning: array_flip() expects parameter 1 to be array, string given in %s on line %d
-NULL
--- Iteration 17 --
-
-Warning: array_flip() expects parameter 1 to be array, string given in %s on line %d
-NULL
--- Iteration 18 --
-
-Warning: array_flip() expects parameter 1 to be array, string given in %s on line %d
-NULL
--- Iteration 19 --
-
-Warning: array_flip() expects parameter 1 to be array, string given in %s on line %d
-NULL
--- Iteration 20 --
-
-Warning: array_flip() expects parameter 1 to be array, object given in %s on line %d
-NULL
--- Iteration 21 --
-
-Warning: array_flip() expects parameter 1 to be array, null given in %s on line %d
-NULL
--- Iteration 22 --
-
-Warning: array_flip() expects parameter 1 to be array, null given in %s on line %d
-NULL
--- Iteration 23 --
-
-Warning: array_flip() expects parameter 1 to be array, resource given in %s on line %d
-NULL
-Done
diff --git a/ext/standard/tests/array/array_key_exists_variation2.phpt b/ext/standard/tests/array/array_key_exists_variation2.phpt
deleted file mode 100644
index b1e3033002..0000000000
--- a/ext/standard/tests/array/array_key_exists_variation2.phpt
+++ /dev/null
@@ -1,224 +0,0 @@
---TEST--
-Test array_key_exists() function : usage variations - Pass different data types to $search arg
---FILE--
-<?php
-/* Prototype : bool array_key_exists(mixed $key, array $search)
- * Description: Checks if the given key or index exists in the array
- * Source code: ext/standard/array.c
- * Alias to functions: key_exists
- */
-
-/*
- * Pass different data types as $search argument to array_key_exists() to test behaviour
- */
-
-echo "*** Testing array_key_exists() : usage variations ***\n";
-
-// Initialise function arguments not being substituted
-$key = 'val';
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// get a class
-class classA
-{
- public function __toString() {
- return "Class A object";
- }
-}
-
-// heredoc string
-$heredoc = <<<EOT
-hello world
-EOT;
-
-// get a resource variable
-$fp = fopen(__FILE__, "r");
-
-// unexpected values to be passed to $search argument
-$inputs = array(
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 12.3456789000e10,
- 12.3456789000E-10,
- .5,
-
- // null data
-/*10*/ NULL,
- null,
-
- // boolean data
-/*12*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*16*/ "",
- '',
- array(),
-
- // string data
-/*19*/ "string",
- 'string',
- $heredoc,
-
- // object data
-/*22*/ new classA(),
-
- // undefined data
-/*23*/ @$undefined_var,
-
- // unset data
-/*24*/ @$unset_var,
-
- // resource variable
-/*25*/ $fp
-);
-
-// loop through each element of $inputs to check the behavior of array_key_exists()
-$iterator = 1;
-foreach($inputs as $input) {
- echo "\n-- Iteration $iterator --\n";
- var_dump( array_key_exists($key, $input) );
- $iterator++;
-};
-
-fclose($fp);
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing array_key_exists() : usage variations ***
-
--- Iteration 1 --
-
-Warning: array_key_exists() expects parameter 2 to be array, int given in %s on line %d
-NULL
-
--- Iteration 2 --
-
-Warning: array_key_exists() expects parameter 2 to be array, int given in %s on line %d
-NULL
-
--- Iteration 3 --
-
-Warning: array_key_exists() expects parameter 2 to be array, int given in %s on line %d
-NULL
-
--- Iteration 4 --
-
-Warning: array_key_exists() expects parameter 2 to be array, int given in %s on line %d
-NULL
-
--- Iteration 5 --
-
-Warning: array_key_exists() expects parameter 2 to be array, float given in %s on line %d
-NULL
-
--- Iteration 6 --
-
-Warning: array_key_exists() expects parameter 2 to be array, float given in %s on line %d
-NULL
-
--- Iteration 7 --
-
-Warning: array_key_exists() expects parameter 2 to be array, float given in %s on line %d
-NULL
-
--- Iteration 8 --
-
-Warning: array_key_exists() expects parameter 2 to be array, float given in %s on line %d
-NULL
-
--- Iteration 9 --
-
-Warning: array_key_exists() expects parameter 2 to be array, float given in %s on line %d
-NULL
-
--- Iteration 10 --
-
-Warning: array_key_exists() expects parameter 2 to be array, null given in %s on line %d
-NULL
-
--- Iteration 11 --
-
-Warning: array_key_exists() expects parameter 2 to be array, null given in %s on line %d
-NULL
-
--- Iteration 12 --
-
-Warning: array_key_exists() expects parameter 2 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 13 --
-
-Warning: array_key_exists() expects parameter 2 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 14 --
-
-Warning: array_key_exists() expects parameter 2 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 15 --
-
-Warning: array_key_exists() expects parameter 2 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 16 --
-
-Warning: array_key_exists() expects parameter 2 to be array, string given in %s on line %d
-NULL
-
--- Iteration 17 --
-
-Warning: array_key_exists() expects parameter 2 to be array, string given in %s on line %d
-NULL
-
--- Iteration 18 --
-bool(false)
-
--- Iteration 19 --
-
-Warning: array_key_exists() expects parameter 2 to be array, string given in %s on line %d
-NULL
-
--- Iteration 20 --
-
-Warning: array_key_exists() expects parameter 2 to be array, string given in %s on line %d
-NULL
-
--- Iteration 21 --
-
-Warning: array_key_exists() expects parameter 2 to be array, string given in %s on line %d
-NULL
-
--- Iteration 22 --
-bool(false)
-
--- Iteration 23 --
-
-Warning: array_key_exists() expects parameter 2 to be array, null given in %s on line %d
-NULL
-
--- Iteration 24 --
-
-Warning: array_key_exists() expects parameter 2 to be array, null given in %s on line %d
-NULL
-
--- Iteration 25 --
-
-Warning: array_key_exists() expects parameter 2 to be array, resource given in %s on line %d
-NULL
-Done
diff --git a/ext/standard/tests/array/array_map_variation18.phpt b/ext/standard/tests/array/array_map_variation18.phpt
deleted file mode 100644
index 4c85d12e88..0000000000
--- a/ext/standard/tests/array/array_map_variation18.phpt
+++ /dev/null
@@ -1,205 +0,0 @@
---TEST--
-Test array_map() function : usage variations - unexpected values for 'arr1' argument
---FILE--
-<?php
-/* Prototype : array array_map ( callback $callback , array $arr1 [, array $... ] )
- * Description: Applies the callback to the elements of the given arrays
- * Source code: ext/standard/array.c
- */
-
-/*
- * Test array_map() by passing non array values in place of $arr1
- */
-
-echo "*** Testing array_map() : unexpected values for 'arr1' ***\n";
-
-function callback($a)
-{
- return $a;
-}
-
-//get an unset array variable
-$unset_var1 = array(1, 2);
-unset ($unset_var1);
-
-// get an unset variable
-$unset_var2 = 10;
-unset ($unset_var2);
-
-// get a class
-class classA
-{
- public function __toString() {
- return "Class A object";
- }
-}
-
-// heredoc string
-$heredoc = <<<EOT
-hello world
-EOT;
-
-// get a resource variable
-$fp = fopen(__FILE__, "r");
-
-// different scalar/non-scalar values for array input
-$unexpected_inputs = array(
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 12.3456789000e10,
- 12.3456789000E-10,
- .5,
-
- // null data
-/*10*/ NULL,
- null,
-
- // boolean data
-/*12*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*16*/ "",
- '',
-
- // string data
-/*18*/ "string",
- 'string',
- $heredoc,
-
- // object data
-/*21*/ new classA(),
-
- // undefined data
-/*22*/ @$undefined_var,
-
- // unset data
-/*23*/ @$unset_var1,
- @$unset_var2,
-
- // resource variable
-/*25*/ $fp
-);
-
-// loop through each element of $unexpected_inputs to check the behavior of array_map
-for($count = 0; $count < count($unexpected_inputs); $count++) {
- echo "-- Iteration ".($count + 1)." --\n";
- var_dump( array_map('callback', $unexpected_inputs[$count]));
-};
-
-fclose($fp);
-echo "Done";
-?>
---EXPECTF--
-*** Testing array_map() : unexpected values for 'arr1' ***
--- Iteration 1 --
-
-Warning: array_map(): Expected parameter 2 to be an array, int given in %s on line %d%d
-NULL
--- Iteration 2 --
-
-Warning: array_map(): Expected parameter 2 to be an array, int given in %s on line %d%d
-NULL
--- Iteration 3 --
-
-Warning: array_map(): Expected parameter 2 to be an array, int given in %s on line %d%d
-NULL
--- Iteration 4 --
-
-Warning: array_map(): Expected parameter 2 to be an array, int given in %s on line %d%d
-NULL
--- Iteration 5 --
-
-Warning: array_map(): Expected parameter 2 to be an array, float given in %s on line %d%d
-NULL
--- Iteration 6 --
-
-Warning: array_map(): Expected parameter 2 to be an array, float given in %s on line %d%d
-NULL
--- Iteration 7 --
-
-Warning: array_map(): Expected parameter 2 to be an array, float given in %s on line %d%d
-NULL
--- Iteration 8 --
-
-Warning: array_map(): Expected parameter 2 to be an array, float given in %s on line %d%d
-NULL
--- Iteration 9 --
-
-Warning: array_map(): Expected parameter 2 to be an array, float given in %s on line %d%d
-NULL
--- Iteration 10 --
-
-Warning: array_map(): Expected parameter 2 to be an array, null given in %s on line %d%d
-NULL
--- Iteration 11 --
-
-Warning: array_map(): Expected parameter 2 to be an array, null given in %s on line %d%d
-NULL
--- Iteration 12 --
-
-Warning: array_map(): Expected parameter 2 to be an array, bool given in %s on line %d%d
-NULL
--- Iteration 13 --
-
-Warning: array_map(): Expected parameter 2 to be an array, bool given in %s on line %d%d
-NULL
--- Iteration 14 --
-
-Warning: array_map(): Expected parameter 2 to be an array, bool given in %s on line %d%d
-NULL
--- Iteration 15 --
-
-Warning: array_map(): Expected parameter 2 to be an array, bool given in %s on line %d%d
-NULL
--- Iteration 16 --
-
-Warning: array_map(): Expected parameter 2 to be an array, string given in %s on line %d%d
-NULL
--- Iteration 17 --
-
-Warning: array_map(): Expected parameter 2 to be an array, string given in %s on line %d%d
-NULL
--- Iteration 18 --
-
-Warning: array_map(): Expected parameter 2 to be an array, string given in %s on line %d%d
-NULL
--- Iteration 19 --
-
-Warning: array_map(): Expected parameter 2 to be an array, string given in %s on line %d%d
-NULL
--- Iteration 20 --
-
-Warning: array_map(): Expected parameter 2 to be an array, string given in %s on line %d%d
-NULL
--- Iteration 21 --
-
-Warning: array_map(): Expected parameter 2 to be an array, object given in %s on line %d%d
-NULL
--- Iteration 22 --
-
-Warning: array_map(): Expected parameter 2 to be an array, null given in %s on line %d%d
-NULL
--- Iteration 23 --
-
-Warning: array_map(): Expected parameter 2 to be an array, null given in %s on line %d%d
-NULL
--- Iteration 24 --
-
-Warning: array_map(): Expected parameter 2 to be an array, null given in %s on line %d%d
-NULL
--- Iteration 25 --
-
-Warning: array_map(): Expected parameter 2 to be an array, resource given in %s on line %d%d
-NULL
-Done
diff --git a/ext/standard/tests/array/array_pad_variation1.phpt b/ext/standard/tests/array/array_pad_variation1.phpt
deleted file mode 100644
index b806139d57..0000000000
--- a/ext/standard/tests/array/array_pad_variation1.phpt
+++ /dev/null
@@ -1,270 +0,0 @@
---TEST--
-Test array_pad() function : usage variations - unexpected values for 'input' argument
---FILE--
-<?php
-/* Prototype : array array_pad(array $input, int $pad_size, mixed $pad_value)
- * Description: Returns a copy of input array padded with pad_value to size pad_size
- * Source code: ext/standard/array.c
-*/
-
-/*
-* Testing array_pad() function by passing values to $input argument other than arrays
-* and see that function outputs proper warning messages wherever expected.
-* The $pad_size and $pad_value arguments passed are fixed values.
-*/
-
-echo "*** Testing array_pad() : passing non array values to \$input argument ***\n";
-
-// Initialise $pad_size and $pad_value
-$pad_size = 10;
-$pad_value = 1;
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// get a class
-class classA
-{
- public function __toString() {
- return "Class A object";
- }
-}
-
-// heredoc string
-$heredoc = <<<EOT
-hello world
-EOT;
-
-// get a resource variable
-$fp = fopen(__FILE__, "r");
-
-// unexpected values to be passed to $input argument
-$inputs = array(
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 12.3456789000e10,
- 12.3456789000E-10,
- .5,
-
- // null data
-/*10*/ NULL,
- null,
-
- // boolean data
-/*12*/ true,
- false,
- TRUE,
- FALSE,
- // empty data
-/*16*/ "",
- '',
-
- // string data
-/*18*/ "string",
- 'string',
- $heredoc,
-
- // object data
-/*21*/ new classA(),
-
- // undefined data
-/*22*/ @$undefined_var,
-
- // unset data
-/*23*/ @$unset_var,
-
- // resource variable
-/*24*/ $fp
-);
-
-// loop through each element of $inputs to check the behavior of array_pad()
-$iterator = 1;
-foreach($inputs as $input) {
- echo "\n-- Iteration $iterator --";
- var_dump( array_pad($input, $pad_size, $pad_value) ); // positive 'pad_size'
- var_dump( array_pad($input, -$pad_size, $pad_value) ); // negative 'pad_size'
- $iterator++;
-};
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing array_pad() : passing non array values to $input argument ***
-
--- Iteration 1 --
-Warning: array_pad() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
-Warning: array_pad() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 2 --
-Warning: array_pad() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
-Warning: array_pad() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 3 --
-Warning: array_pad() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
-Warning: array_pad() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 4 --
-Warning: array_pad() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
-Warning: array_pad() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 5 --
-Warning: array_pad() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
-Warning: array_pad() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 6 --
-Warning: array_pad() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
-Warning: array_pad() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 7 --
-Warning: array_pad() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
-Warning: array_pad() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 8 --
-Warning: array_pad() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
-Warning: array_pad() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 9 --
-Warning: array_pad() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
-Warning: array_pad() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 10 --
-Warning: array_pad() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
-Warning: array_pad() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 11 --
-Warning: array_pad() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
-Warning: array_pad() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 12 --
-Warning: array_pad() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
-Warning: array_pad() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 13 --
-Warning: array_pad() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
-Warning: array_pad() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 14 --
-Warning: array_pad() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
-Warning: array_pad() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 15 --
-Warning: array_pad() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
-Warning: array_pad() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 16 --
-Warning: array_pad() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
-Warning: array_pad() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 17 --
-Warning: array_pad() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
-Warning: array_pad() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 18 --
-Warning: array_pad() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
-Warning: array_pad() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 19 --
-Warning: array_pad() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
-Warning: array_pad() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 20 --
-Warning: array_pad() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
-Warning: array_pad() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 21 --
-Warning: array_pad() expects parameter 1 to be array, object given in %s on line %d
-NULL
-
-Warning: array_pad() expects parameter 1 to be array, object given in %s on line %d
-NULL
-
--- Iteration 22 --
-Warning: array_pad() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
-Warning: array_pad() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 23 --
-Warning: array_pad() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
-Warning: array_pad() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 24 --
-Warning: array_pad() expects parameter 1 to be array, resource given in %s on line %d
-NULL
-
-Warning: array_pad() expects parameter 1 to be array, resource given in %s on line %d
-NULL
-Done
diff --git a/ext/standard/tests/array/array_pad_variation2.phpt b/ext/standard/tests/array/array_pad_variation2.phpt
deleted file mode 100644
index c95303974d..0000000000
--- a/ext/standard/tests/array/array_pad_variation2.phpt
+++ /dev/null
@@ -1,258 +0,0 @@
---TEST--
-Test array_pad() function : usage variations - unexpected values for 'pad_size' argument(Bug#43482)
---SKIPIF--
-<?php if (PHP_INT_SIZE != 8) die("skip this test is for 64-bit only");
---FILE--
-<?php
-/* Prototype : array array_pad(array $input, int $pad_size, mixed $pad_value)
- * Description: Returns a copy of input array padded with pad_value to size pad_size
- * Source code: ext/standard/array.c
-*/
-
-/*
-* Testing array_pad() function by passing values to $pad_size argument other than integers
-* and see that function outputs proper warning messages wherever expected.
-* The $input and $pad_value arguments passed are fixed values.
-*/
-
-echo "*** Testing array_pad() : passing non integer values to \$pad_size argument ***\n";
-
-// Initialise $input and $pad_value arguments
-$input = array(1, 2);
-$pad_value = 1;
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// get a class
-class classA
-{
- public function __toString() {
- return "Class A object";
- }
-}
-
-//array of values to iterate over
-$pad_sizes = array(
-
- // float data
-/*1*/ 10.5,
- -10.5,
- 12.3456789000e10,
- -12.3456789000e10,
- 12.3456789000E-10,
- .5,
-
- // array data
-/*6*/ array(),
- array(0),
- array(1),
- array(1, 2),
- array('color' => 'red', 'item' => 'pen'),
-
- // null data
-/*11*/ NULL,
- null,
-
- // boolean data
-/*13*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*17*/ "",
- '',
-
- // string data
-/*19*/ "string",
- 'string',
-
- // object data
-/*21*/ new classA(),
-
- // undefined data
-/*22*/ @$undefined_var,
-
- // unset data
-/*23*/ @$unset_var,
-);
-
-// loop through each element of $pad_sizes to check the behavior of array_pad()
-$iterator = 1;
-foreach($pad_sizes as $pad_size) {
- echo "-- Iteration $iterator --\n";
- var_dump( array_pad($input, $pad_size, $pad_value) );
- $iterator++;
-};
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing array_pad() : passing non integer values to $pad_size argument ***
--- Iteration 1 --
-array(10) {
- [0]=>
- int(1)
- [1]=>
- int(2)
- [2]=>
- int(1)
- [3]=>
- int(1)
- [4]=>
- int(1)
- [5]=>
- int(1)
- [6]=>
- int(1)
- [7]=>
- int(1)
- [8]=>
- int(1)
- [9]=>
- int(1)
-}
--- Iteration 2 --
-array(10) {
- [0]=>
- int(1)
- [1]=>
- int(1)
- [2]=>
- int(1)
- [3]=>
- int(1)
- [4]=>
- int(1)
- [5]=>
- int(1)
- [6]=>
- int(1)
- [7]=>
- int(1)
- [8]=>
- int(1)
- [9]=>
- int(2)
-}
--- Iteration 3 --
-
-Warning: array_pad(): You may only pad up to 1048576 elements at a time in %s on line %d
-bool(false)
--- Iteration 4 --
-
-Warning: array_pad(): You may only pad up to 1048576 elements at a time in %s on line %d
-bool(false)
--- Iteration 5 --
-array(2) {
- [0]=>
- int(1)
- [1]=>
- int(2)
-}
--- Iteration 6 --
-array(2) {
- [0]=>
- int(1)
- [1]=>
- int(2)
-}
--- Iteration 7 --
-
-Warning: array_pad() expects parameter 2 to be int, array given in %s on line %d
-NULL
--- Iteration 8 --
-
-Warning: array_pad() expects parameter 2 to be int, array given in %s on line %d
-NULL
--- Iteration 9 --
-
-Warning: array_pad() expects parameter 2 to be int, array given in %s on line %d
-NULL
--- Iteration 10 --
-
-Warning: array_pad() expects parameter 2 to be int, array given in %s on line %d
-NULL
--- Iteration 11 --
-
-Warning: array_pad() expects parameter 2 to be int, array given in %s on line %d
-NULL
--- Iteration 12 --
-array(2) {
- [0]=>
- int(1)
- [1]=>
- int(2)
-}
--- Iteration 13 --
-array(2) {
- [0]=>
- int(1)
- [1]=>
- int(2)
-}
--- Iteration 14 --
-array(2) {
- [0]=>
- int(1)
- [1]=>
- int(2)
-}
--- Iteration 15 --
-array(2) {
- [0]=>
- int(1)
- [1]=>
- int(2)
-}
--- Iteration 16 --
-array(2) {
- [0]=>
- int(1)
- [1]=>
- int(2)
-}
--- Iteration 17 --
-array(2) {
- [0]=>
- int(1)
- [1]=>
- int(2)
-}
--- Iteration 18 --
-
-Warning: array_pad() expects parameter 2 to be int, string given in %s on line %d
-NULL
--- Iteration 19 --
-
-Warning: array_pad() expects parameter 2 to be int, string given in %s on line %d
-NULL
--- Iteration 20 --
-
-Warning: array_pad() expects parameter 2 to be int, string given in %s on line %d
-NULL
--- Iteration 21 --
-
-Warning: array_pad() expects parameter 2 to be int, string given in %s on line %d
-NULL
--- Iteration 22 --
-
-Warning: array_pad() expects parameter 2 to be int, object given in %s on line %d
-NULL
--- Iteration 23 --
-array(2) {
- [0]=>
- int(1)
- [1]=>
- int(2)
-}
--- Iteration 24 --
-array(2) {
- [0]=>
- int(1)
- [1]=>
- int(2)
-}
-Done
diff --git a/ext/standard/tests/array/array_product_variation5.phpt b/ext/standard/tests/array/array_product_variation5.phpt
deleted file mode 100644
index 09284d9096..0000000000
--- a/ext/standard/tests/array/array_product_variation5.phpt
+++ /dev/null
@@ -1,223 +0,0 @@
---TEST--
-Test array_product() function : usage variation
---FILE--
-<?php
-/* Prototype : mixed array_product(array input)
- * Description: Returns the product of the array entries
- * Source code: ext/standard/array.c
- * Alias to functions:
- */
-
-echo "*** Testing array_product() : usage variation ***\n";
-
-// Initialise function arguments not being substituted (if any)
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// define some classes
-class classWithToString
-{
- public function __toString() {
- return "Class A object";
- }
-}
-
-class classWithoutToString
-{
-}
-
-// heredoc string
-$heredoc = <<<EOT
-hello world
-EOT;
-
-// add arrays
-$index_array = array (1, 2, 3);
-$assoc_array = array ('one' => 1, 'two' => 2);
-
-//array of values to iterate over
-$inputs = array(
-
- // int data
- 'int 0' => 0,
- 'int 1' => 1,
- 'int 12345' => 12345,
- 'int -12345' => -2345,
-
- // float data
- 'float 10.5' => 10.5,
- 'float -10.5' => -10.5,
- 'float 12.3456789000e10' => 12.3456789000e10,
- 'float -12.3456789000e10' => -12.3456789000e10,
- 'float .5' => .5,
-
- // null data
- 'uppercase NULL' => NULL,
- 'lowercase null' => null,
-
- // boolean data
- 'lowercase true' => true,
- 'lowercase false' =>false,
- 'uppercase TRUE' =>TRUE,
- 'uppercase FALSE' =>FALSE,
-
- // empty data
- 'empty string DQ' => "",
- 'empty string SQ' => '',
-
- // string data
- 'string DQ' => "string",
- 'string SQ' => 'string',
- 'mixed case string' => "sTrInG",
- 'heredoc' => $heredoc,
-
- // object data
- 'instance of classWithToString' => new classWithToString(),
- 'instance of classWithoutToString' => new classWithoutToString(),
-
- // undefined data
- 'undefined var' => @$undefined_var,
-
- // unset data
- 'unset var' => @$unset_var,
-);
-
-// loop through each element of the array for input
-
-foreach($inputs as $key =>$value) {
- echo "\n--$key--\n";
- var_dump( array_product($value) );
-};
-
-?>
-===DONE===
---EXPECTF--
-*** Testing array_product() : usage variation ***
-
---int 0--
-
-Warning: array_product() expects parameter 1 to be array, int given in %sarray_product_variation5.php on line %d
-NULL
-
---int 1--
-
-Warning: array_product() expects parameter 1 to be array, int given in %sarray_product_variation5.php on line %d
-NULL
-
---int 12345--
-
-Warning: array_product() expects parameter 1 to be array, int given in %sarray_product_variation5.php on line %d
-NULL
-
---int -12345--
-
-Warning: array_product() expects parameter 1 to be array, int given in %sarray_product_variation5.php on line %d
-NULL
-
---float 10.5--
-
-Warning: array_product() expects parameter 1 to be array, float given in %sarray_product_variation5.php on line %d
-NULL
-
---float -10.5--
-
-Warning: array_product() expects parameter 1 to be array, float given in %sarray_product_variation5.php on line %d
-NULL
-
---float 12.3456789000e10--
-
-Warning: array_product() expects parameter 1 to be array, float given in %sarray_product_variation5.php on line %d
-NULL
-
---float -12.3456789000e10--
-
-Warning: array_product() expects parameter 1 to be array, float given in %sarray_product_variation5.php on line %d
-NULL
-
---float .5--
-
-Warning: array_product() expects parameter 1 to be array, float given in %sarray_product_variation5.php on line %d
-NULL
-
---uppercase NULL--
-
-Warning: array_product() expects parameter 1 to be array, null given in %sarray_product_variation5.php on line %d
-NULL
-
---lowercase null--
-
-Warning: array_product() expects parameter 1 to be array, null given in %sarray_product_variation5.php on line %d
-NULL
-
---lowercase true--
-
-Warning: array_product() expects parameter 1 to be array, bool given in %sarray_product_variation5.php on line %d
-NULL
-
---lowercase false--
-
-Warning: array_product() expects parameter 1 to be array, bool given in %sarray_product_variation5.php on line %d
-NULL
-
---uppercase TRUE--
-
-Warning: array_product() expects parameter 1 to be array, bool given in %sarray_product_variation5.php on line %d
-NULL
-
---uppercase FALSE--
-
-Warning: array_product() expects parameter 1 to be array, bool given in %sarray_product_variation5.php on line %d
-NULL
-
---empty string DQ--
-
-Warning: array_product() expects parameter 1 to be array, string given in %sarray_product_variation5.php on line %d
-NULL
-
---empty string SQ--
-
-Warning: array_product() expects parameter 1 to be array, string given in %sarray_product_variation5.php on line %d
-NULL
-
---string DQ--
-
-Warning: array_product() expects parameter 1 to be array, string given in %sarray_product_variation5.php on line %d
-NULL
-
---string SQ--
-
-Warning: array_product() expects parameter 1 to be array, string given in %sarray_product_variation5.php on line %d
-NULL
-
---mixed case string--
-
-Warning: array_product() expects parameter 1 to be array, string given in %sarray_product_variation5.php on line %d
-NULL
-
---heredoc--
-
-Warning: array_product() expects parameter 1 to be array, string given in %sarray_product_variation5.php on line %d
-NULL
-
---instance of classWithToString--
-
-Warning: array_product() expects parameter 1 to be array, object given in %sarray_product_variation5.php on line %d
-NULL
-
---instance of classWithoutToString--
-
-Warning: array_product() expects parameter 1 to be array, object given in %sarray_product_variation5.php on line %d
-NULL
-
---undefined var--
-
-Warning: array_product() expects parameter 1 to be array, null given in %sarray_product_variation5.php on line %d
-NULL
-
---unset var--
-
-Warning: array_product() expects parameter 1 to be array, null given in %sarray_product_variation5.php on line %d
-NULL
-===DONE===
diff --git a/ext/standard/tests/array/array_push_variation1.phpt b/ext/standard/tests/array/array_push_variation1.phpt
deleted file mode 100644
index c04cf4073f..0000000000
--- a/ext/standard/tests/array/array_push_variation1.phpt
+++ /dev/null
@@ -1,225 +0,0 @@
---TEST--
-Test array_push() function : usage variations - Pass different data types as $stack arg
---FILE--
-<?php
-/* Prototype : int array_push(array $stack, mixed $var [, mixed $...])
- * Description: Pushes elements onto the end of the array
- * Source code: ext/standard/array.c
- */
-
-/*
- * Pass different data types as $stack argument to array_push() to test behaviour
- */
-
-echo "*** Testing array_push() : usage variations ***\n";
-
-// Initialise function arguments not being substituted
-$var = 'value';
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// get a class
-class classA
-{
- public function __toString() {
- return "Class A object";
- }
-}
-
-// heredoc string
-$heredoc = <<<EOT
-hello world
-EOT;
-
-// get a resource variable
-$fp = fopen(__FILE__, "r");
-
-// unexpected values to be passed to $stack argument
-$inputs = array(
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 12.3456789000e10,
- 12.3456789000E-10,
- .5,
-
- // null data
-/*10*/ NULL,
- null,
-
- // boolean data
-/*12*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*16*/ "",
- '',
- array(),
-
- // string data
-/*19*/ "string",
- 'string',
- $heredoc,
-
- // object data
-/*22*/ new classA(),
-
- // undefined data
-/*23*/ @$undefined_var,
-
- // unset data
-/*24*/ @$unset_var,
-
- // resource variable
-/*25*/ $fp
-);
-
-// loop through each element of $inputs to check the behavior of array_push()
-$iterator = 1;
-foreach($inputs as $input) {
- echo "\n-- Iteration $iterator --\n";
- var_dump( array_push($input, $var) );
- $iterator++;
-};
-
-fclose($fp);
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing array_push() : usage variations ***
-
--- Iteration 1 --
-
-Warning: array_push() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 2 --
-
-Warning: array_push() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 3 --
-
-Warning: array_push() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 4 --
-
-Warning: array_push() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 5 --
-
-Warning: array_push() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 6 --
-
-Warning: array_push() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 7 --
-
-Warning: array_push() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 8 --
-
-Warning: array_push() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 9 --
-
-Warning: array_push() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 10 --
-
-Warning: array_push() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 11 --
-
-Warning: array_push() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 12 --
-
-Warning: array_push() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 13 --
-
-Warning: array_push() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 14 --
-
-Warning: array_push() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 15 --
-
-Warning: array_push() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 16 --
-
-Warning: array_push() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 17 --
-
-Warning: array_push() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 18 --
-int(1)
-
--- Iteration 19 --
-
-Warning: array_push() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 20 --
-
-Warning: array_push() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 21 --
-
-Warning: array_push() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 22 --
-
-Warning: array_push() expects parameter 1 to be array, object given in %s on line %d
-NULL
-
--- Iteration 23 --
-
-Warning: array_push() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 24 --
-
-Warning: array_push() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 25 --
-
-Warning: array_push() expects parameter 1 to be array, resource given in %s on line %d
-NULL
-Done
diff --git a/ext/standard/tests/array/array_rand_variation1.phpt b/ext/standard/tests/array/array_rand_variation1.phpt
deleted file mode 100644
index 7aaf48f99f..0000000000
--- a/ext/standard/tests/array/array_rand_variation1.phpt
+++ /dev/null
@@ -1,216 +0,0 @@
---TEST--
-Test array_rand() function : usage variations - unexpected values for 'input' parameter
---FILE--
-<?php
-/* Prototype : mixed array_rand(array input [, int num_req])
- * Description: Return key/keys for random entry/entries in the array
- * Source code: ext/standard/array.c
-*/
-
-/*
-* Test array_rand() with different types of values other than arrays passed to the 'input' parameter
-* to see that function works with unexpeced data and generates warning message as required.
-*/
-
-echo "*** Testing array_rand() : unexpected values for 'input' parameter ***\n";
-
-// Initialise function arguments
-$num_req = 10;
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-//get a resource variable
-$fp = fopen(__FILE__, "r");
-
-//define a class
-class test
-{
- var $t = 10;
- function __toString()
- {
- return "object";
- }
-}
-
-//array of different values for 'input' parameter
-$values = array(
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 12.3456789000e10,
- 12.3456789000E-10,
- .5,
-
- // null data
-/*10*/ NULL,
- null,
-
- // boolean data
-/*12*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*16*/ "",
- '',
-
- // string data
-/*18*/ "string",
- 'string',
-
- // object data
-/*20*/ new test(),
-
- // resource data
-/*21*/ $fp,
-
- // undefined data
-/*22*/ @$undefined_var,
-
- // unset data
-/*23*/ @$unset_var,
-);
-
-/* loop through each element of the array to test array_rand() function
- * for different values for 'input' argument
-*/
-$count = 1;
-foreach($values as $value) {
- echo "\n-- Iteration $count --\n";
- var_dump( array_rand($value,$num_req) );
- $count++;
-};
-
-// closing the resource
-fclose($fp);
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing array_rand() : unexpected values for 'input' parameter ***
-
--- Iteration 1 --
-
-Warning: array_rand() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 2 --
-
-Warning: array_rand() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 3 --
-
-Warning: array_rand() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 4 --
-
-Warning: array_rand() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 5 --
-
-Warning: array_rand() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 6 --
-
-Warning: array_rand() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 7 --
-
-Warning: array_rand() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 8 --
-
-Warning: array_rand() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 9 --
-
-Warning: array_rand() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 10 --
-
-Warning: array_rand() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 11 --
-
-Warning: array_rand() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 12 --
-
-Warning: array_rand() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 13 --
-
-Warning: array_rand() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 14 --
-
-Warning: array_rand() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 15 --
-
-Warning: array_rand() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 16 --
-
-Warning: array_rand() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 17 --
-
-Warning: array_rand() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 18 --
-
-Warning: array_rand() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 19 --
-
-Warning: array_rand() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 20 --
-
-Warning: array_rand() expects parameter 1 to be array, object given in %s on line %d
-NULL
-
--- Iteration 21 --
-
-Warning: array_rand() expects parameter 1 to be array, resource given in %s on line %d
-NULL
-
--- Iteration 22 --
-
-Warning: array_rand() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 23 --
-
-Warning: array_rand() expects parameter 1 to be array, null given in %s on line %d
-NULL
-Done
diff --git a/ext/standard/tests/array/array_rand_variation2.phpt b/ext/standard/tests/array/array_rand_variation2.phpt
deleted file mode 100644
index 1182d1aeea..0000000000
--- a/ext/standard/tests/array/array_rand_variation2.phpt
+++ /dev/null
@@ -1,216 +0,0 @@
---TEST--
-Test array_rand() function : usage variations - unexpected values for 'num_req' parameter
---SKIPIF--
-<?php if (PHP_INT_SIZE != 8) die("skip this test is for 64-bit only");
---FILE--
-<?php
-/* Prototype : mixed array_rand(array input [, int num_req])
- * Description: Return key/keys for random entry/entries in the array
- * Source code: ext/standard/array.c
-*/
-
-/*
-* Test array_rand() with different types of values other than int passed to 'num_req' argument
-* to see that function works with unexpeced data and generates warning message as required.
-*/
-
-echo "*** Testing array_rand() : unexpected values for 'num_req' parameter ***\n";
-
-// Initialise function arguments
-$input = array(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13);
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-//define a class
-class test
-{
- var $t = 10;
- function __toString()
- {
- return "3object";
- }
-}
-
-//array of values to iterate over
-$values = array(
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 12.3456789000e10,
- 12.3456789000E-10,
- .5,
-
- // null data
-/*10*/ NULL,
- null,
-
- // boolean data
-/*12*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*16*/ "",
- '',
-
- // string data
-/*18*/ "string",
- 'string',
-
- // object data
-/*20*/ new test(),
-
- // undefined data
-/*21*/ @$undefined_var,
-
- // unset data
-/*22*/ @$unset_var,
-);
-
-
-// loop through each element of the array for different values for 'num_req' argument
-$count = 1;
-foreach($values as $value) {
- echo "\n-- Iteration $count --\n";
- var_dump( array_rand($input,$value) );
- $count++;
-};
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing array_rand() : unexpected values for 'num_req' parameter ***
-
--- Iteration 1 --
-
-Warning: array_rand(): Second argument has to be between 1 and the number of elements in the array in %s on line %d
-NULL
-
--- Iteration 2 --
-int(%d)
-
--- Iteration 3 --
-
-Warning: array_rand(): Second argument has to be between 1 and the number of elements in the array in %s on line %d
-NULL
-
--- Iteration 4 --
-
-Warning: array_rand(): Second argument has to be between 1 and the number of elements in the array in %s on line %d
-NULL
-
--- Iteration 5 --
-array(10) {
- [0]=>
- int(%d)
- [1]=>
- int(%d)
- [2]=>
- int(%d)
- [3]=>
- int(%d)
- [4]=>
- int(%d)
- [5]=>
- int(%d)
- [6]=>
- int(%d)
- [7]=>
- int(%d)
- [8]=>
- int(%d)
- [9]=>
- int(%d)
-}
-
--- Iteration 6 --
-
-Warning: array_rand(): Second argument has to be between 1 and the number of elements in the array in %s on line %d
-NULL
-
--- Iteration 7 --
-
-Warning: array_rand(): Second argument has to be between 1 and the number of elements in the array in %s on line %d
-NULL
-
--- Iteration 8 --
-
-Warning: array_rand(): Second argument has to be between 1 and the number of elements in the array in %s on line %d
-NULL
-
--- Iteration 9 --
-
-Warning: array_rand(): Second argument has to be between 1 and the number of elements in the array in %s on line %d
-NULL
-
--- Iteration 10 --
-
-Warning: array_rand(): Second argument has to be between 1 and the number of elements in the array in %s on line %d
-NULL
-
--- Iteration 11 --
-
-Warning: array_rand(): Second argument has to be between 1 and the number of elements in the array in %s on line %d
-NULL
-
--- Iteration 12 --
-int(%d)
-
--- Iteration 13 --
-
-Warning: array_rand(): Second argument has to be between 1 and the number of elements in the array in %s on line %d
-NULL
-
--- Iteration 14 --
-int(%d)
-
--- Iteration 15 --
-
-Warning: array_rand(): Second argument has to be between 1 and the number of elements in the array in %s on line %d
-NULL
-
--- Iteration 16 --
-
-Warning: array_rand() expects parameter 2 to be int, string given in %s on line %d
-NULL
-
--- Iteration 17 --
-
-Warning: array_rand() expects parameter 2 to be int, string given in %s on line %d
-NULL
-
--- Iteration 18 --
-
-Warning: array_rand() expects parameter 2 to be int, string given in %s on line %d
-NULL
-
--- Iteration 19 --
-
-Warning: array_rand() expects parameter 2 to be int, string given in %s on line %d
-NULL
-
--- Iteration 20 --
-
-Warning: array_rand() expects parameter 2 to be int, object given in %s on line %d
-NULL
-
--- Iteration 21 --
-
-Warning: array_rand(): Second argument has to be between 1 and the number of elements in the array in %s on line %d
-NULL
-
--- Iteration 22 --
-
-Warning: array_rand(): Second argument has to be between 1 and the number of elements in the array in %s on line %d
-NULL
-Done
diff --git a/ext/standard/tests/array/array_reverse_variation1.phpt b/ext/standard/tests/array/array_reverse_variation1.phpt
deleted file mode 100644
index b2936c171c..0000000000
--- a/ext/standard/tests/array/array_reverse_variation1.phpt
+++ /dev/null
@@ -1,340 +0,0 @@
---TEST--
-Test array_reverse() function : usage variations - unexpected values for 'array' argument
---FILE--
-<?php
-/* Prototype : array array_reverse(array $array [, bool $preserve_keys])
- * Description: Return input as a new array with the order of the entries reversed
- * Source code: ext/standard/array.c
-*/
-
-echo "*** Testing array_reverse() : usage variations - unexpected values for 'array' argument ***\n";
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-//get a resource variable
-$fp = fopen(__FILE__, "r");
-
-//get a class
-class classA
-{
- public function __toString(){
- return "Class A object";
- }
-}
-
-//get a heredoc string
-$heredoc_string = <<<EOT
-Hello world\t\n
-EOT;
-
-//array of values to iterate over
-$arrays = array (
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 10.5e10,
- 10.6E-10,
- .5,
-
- // null data
-/*10*/ NULL,
- null,
-
- // boolean data
- true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*16*/ "",
- '',
-
- // string data
- 'Hello world',
- "Hello world",
- $heredoc_string,
-
- // object data
-/*21*/ new classA(),
-
- // undefined data
- @$undefined_var,
-
- // unset data
- @$unset_var,
-
- // resource variable
-/*24*/ $fp
-
-);
-
-// loop through each element of the array $arrays to check the behavior of array_reverse()
-$iterator = 1;
-foreach($arrays as $array) {
- echo "\n-- Iteration $iterator --";
- // with default argument
- var_dump( array_reverse($array) );
- // with all possible arguments
- var_dump( array_reverse($array, true) );
- var_dump( array_reverse($array, false) );
- $iterator++;
-};
-
-// close the file resource used
-fclose($fp);
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing array_reverse() : usage variations - unexpected values for 'array' argument ***
-
--- Iteration 1 --
-Warning: array_reverse() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 2 --
-Warning: array_reverse() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 3 --
-Warning: array_reverse() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 4 --
-Warning: array_reverse() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 5 --
-Warning: array_reverse() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 6 --
-Warning: array_reverse() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 7 --
-Warning: array_reverse() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 8 --
-Warning: array_reverse() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 9 --
-Warning: array_reverse() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 10 --
-Warning: array_reverse() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 11 --
-Warning: array_reverse() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 12 --
-Warning: array_reverse() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 13 --
-Warning: array_reverse() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 14 --
-Warning: array_reverse() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 15 --
-Warning: array_reverse() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 16 --
-Warning: array_reverse() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 17 --
-Warning: array_reverse() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 18 --
-Warning: array_reverse() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 19 --
-Warning: array_reverse() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 20 --
-Warning: array_reverse() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 21 --
-Warning: array_reverse() expects parameter 1 to be array, object given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, object given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, object given in %s on line %d
-NULL
-
--- Iteration 22 --
-Warning: array_reverse() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 23 --
-Warning: array_reverse() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 24 --
-Warning: array_reverse() expects parameter 1 to be array, resource given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, resource given in %s on line %d
-NULL
-
-Warning: array_reverse() expects parameter 1 to be array, resource given in %s on line %d
-NULL
-Done
diff --git a/ext/standard/tests/array/array_reverse_variation2.phpt b/ext/standard/tests/array/array_reverse_variation2.phpt
deleted file mode 100644
index 1cc9a3088e..0000000000
--- a/ext/standard/tests/array/array_reverse_variation2.phpt
+++ /dev/null
@@ -1,414 +0,0 @@
---TEST--
-Test array_reverse() function : usage variations - unexpected values for 'preserve_keys' argument
---FILE--
-<?php
-/* Prototype : array array_reverse(array $array [, bool $preserve_keys])
- * Description: Return input as a new array with the order of the entries reversed
- * Source code: ext/standard/array.c
-*/
-
-/*
- * testing the functionality of array_reverse() by giving unexpected values for $preserve_keys argument
-*/
-
-echo "*** Testing array_reverse() : usage variations ***\n";
-
-// Initialise the array
-$array = array("a" => "green", "red", "blue", "red", "orange", "pink");
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-//get a resource variable
-$fp = fopen(__FILE__, "r");
-
-//get a class
-class classA
-{
- public function __toString(){
- return "Class A object";
- }
-}
-
-//array of values to iterate over
-$preserve_keys = array (
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 10.5e10,
- 10.6E-10,
- .5,
-
- // array data
-/*10*/ array(),
- array(0),
- array(1),
- array(1, 2),
- array('color' => 'red', 'item' => 'pen'),
-
- // null data
-/*15*/ NULL,
- null,
-
- // boolean data
- true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*21*/
- "",
- '',
-
- // object data
- new classA(),
-
- // undefined data
- @$undefined_var,
-
- // unset data
- @$unset_var,
-
- // resource variable
-/*26*/ $fp
-
-);
-
-// loop through each element of the array $preserve_keys to check the behavior of array_reverse()
-$iterator = 1;
-foreach($preserve_keys as $preserve_key) {
- echo "-- Iteration $iterator --\n";
- var_dump( array_reverse($array, $preserve_key) );
- $iterator++;
-};
-
-// close the file resouce used
-fclose($fp);
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing array_reverse() : usage variations ***
--- Iteration 1 --
-array(6) {
- [0]=>
- string(4) "pink"
- [1]=>
- string(6) "orange"
- [2]=>
- string(3) "red"
- [3]=>
- string(4) "blue"
- [4]=>
- string(3) "red"
- ["a"]=>
- string(5) "green"
-}
--- Iteration 2 --
-array(6) {
- [4]=>
- string(4) "pink"
- [3]=>
- string(6) "orange"
- [2]=>
- string(3) "red"
- [1]=>
- string(4) "blue"
- [0]=>
- string(3) "red"
- ["a"]=>
- string(5) "green"
-}
--- Iteration 3 --
-array(6) {
- [4]=>
- string(4) "pink"
- [3]=>
- string(6) "orange"
- [2]=>
- string(3) "red"
- [1]=>
- string(4) "blue"
- [0]=>
- string(3) "red"
- ["a"]=>
- string(5) "green"
-}
--- Iteration 4 --
-array(6) {
- [4]=>
- string(4) "pink"
- [3]=>
- string(6) "orange"
- [2]=>
- string(3) "red"
- [1]=>
- string(4) "blue"
- [0]=>
- string(3) "red"
- ["a"]=>
- string(5) "green"
-}
--- Iteration 5 --
-array(6) {
- [4]=>
- string(4) "pink"
- [3]=>
- string(6) "orange"
- [2]=>
- string(3) "red"
- [1]=>
- string(4) "blue"
- [0]=>
- string(3) "red"
- ["a"]=>
- string(5) "green"
-}
--- Iteration 6 --
-array(6) {
- [4]=>
- string(4) "pink"
- [3]=>
- string(6) "orange"
- [2]=>
- string(3) "red"
- [1]=>
- string(4) "blue"
- [0]=>
- string(3) "red"
- ["a"]=>
- string(5) "green"
-}
--- Iteration 7 --
-array(6) {
- [4]=>
- string(4) "pink"
- [3]=>
- string(6) "orange"
- [2]=>
- string(3) "red"
- [1]=>
- string(4) "blue"
- [0]=>
- string(3) "red"
- ["a"]=>
- string(5) "green"
-}
--- Iteration 8 --
-array(6) {
- [4]=>
- string(4) "pink"
- [3]=>
- string(6) "orange"
- [2]=>
- string(3) "red"
- [1]=>
- string(4) "blue"
- [0]=>
- string(3) "red"
- ["a"]=>
- string(5) "green"
-}
--- Iteration 9 --
-array(6) {
- [4]=>
- string(4) "pink"
- [3]=>
- string(6) "orange"
- [2]=>
- string(3) "red"
- [1]=>
- string(4) "blue"
- [0]=>
- string(3) "red"
- ["a"]=>
- string(5) "green"
-}
--- Iteration 10 --
-
-Warning: array_reverse() expects parameter 2 to be bool, array given in %s on line %d
-NULL
--- Iteration 11 --
-
-Warning: array_reverse() expects parameter 2 to be bool, array given in %s on line %d
-NULL
--- Iteration 12 --
-
-Warning: array_reverse() expects parameter 2 to be bool, array given in %s on line %d
-NULL
--- Iteration 13 --
-
-Warning: array_reverse() expects parameter 2 to be bool, array given in %s on line %d
-NULL
--- Iteration 14 --
-
-Warning: array_reverse() expects parameter 2 to be bool, array given in %s on line %d
-NULL
--- Iteration 15 --
-array(6) {
- [0]=>
- string(4) "pink"
- [1]=>
- string(6) "orange"
- [2]=>
- string(3) "red"
- [3]=>
- string(4) "blue"
- [4]=>
- string(3) "red"
- ["a"]=>
- string(5) "green"
-}
--- Iteration 16 --
-array(6) {
- [0]=>
- string(4) "pink"
- [1]=>
- string(6) "orange"
- [2]=>
- string(3) "red"
- [3]=>
- string(4) "blue"
- [4]=>
- string(3) "red"
- ["a"]=>
- string(5) "green"
-}
--- Iteration 17 --
-array(6) {
- [4]=>
- string(4) "pink"
- [3]=>
- string(6) "orange"
- [2]=>
- string(3) "red"
- [1]=>
- string(4) "blue"
- [0]=>
- string(3) "red"
- ["a"]=>
- string(5) "green"
-}
--- Iteration 18 --
-array(6) {
- [0]=>
- string(4) "pink"
- [1]=>
- string(6) "orange"
- [2]=>
- string(3) "red"
- [3]=>
- string(4) "blue"
- [4]=>
- string(3) "red"
- ["a"]=>
- string(5) "green"
-}
--- Iteration 19 --
-array(6) {
- [4]=>
- string(4) "pink"
- [3]=>
- string(6) "orange"
- [2]=>
- string(3) "red"
- [1]=>
- string(4) "blue"
- [0]=>
- string(3) "red"
- ["a"]=>
- string(5) "green"
-}
--- Iteration 20 --
-array(6) {
- [0]=>
- string(4) "pink"
- [1]=>
- string(6) "orange"
- [2]=>
- string(3) "red"
- [3]=>
- string(4) "blue"
- [4]=>
- string(3) "red"
- ["a"]=>
- string(5) "green"
-}
--- Iteration 21 --
-array(6) {
- [0]=>
- string(4) "pink"
- [1]=>
- string(6) "orange"
- [2]=>
- string(3) "red"
- [3]=>
- string(4) "blue"
- [4]=>
- string(3) "red"
- ["a"]=>
- string(5) "green"
-}
--- Iteration 22 --
-array(6) {
- [0]=>
- string(4) "pink"
- [1]=>
- string(6) "orange"
- [2]=>
- string(3) "red"
- [3]=>
- string(4) "blue"
- [4]=>
- string(3) "red"
- ["a"]=>
- string(5) "green"
-}
--- Iteration 23 --
-
-Warning: array_reverse() expects parameter 2 to be bool, object given in %s on line %d
-NULL
--- Iteration 24 --
-array(6) {
- [0]=>
- string(4) "pink"
- [1]=>
- string(6) "orange"
- [2]=>
- string(3) "red"
- [3]=>
- string(4) "blue"
- [4]=>
- string(3) "red"
- ["a"]=>
- string(5) "green"
-}
--- Iteration 25 --
-array(6) {
- [0]=>
- string(4) "pink"
- [1]=>
- string(6) "orange"
- [2]=>
- string(3) "red"
- [3]=>
- string(4) "blue"
- [4]=>
- string(3) "red"
- ["a"]=>
- string(5) "green"
-}
--- Iteration 26 --
-
-Warning: array_reverse() expects parameter 2 to be bool, resource given in %s on line %d
-NULL
-Done
diff --git a/ext/standard/tests/array/array_shift_variation1.phpt b/ext/standard/tests/array/array_shift_variation1.phpt
deleted file mode 100644
index 5734da4fb9..0000000000
--- a/ext/standard/tests/array/array_shift_variation1.phpt
+++ /dev/null
@@ -1,218 +0,0 @@
---TEST--
-Test array_shift() function : usage variations - Pass different data types as $stack arg
---FILE--
-<?php
-/* Prototype : mixed array_shift(array &$stack)
- * Description: Pops an element off the beginning of the array
- * Source code: ext/standard/array.c
- */
-
-/*
- * Pass different data types as $stack argument to array_shift() to test behaviour
- */
-
-echo "*** Testing array_shift() : usage variations ***\n";
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// get a class
-class classA
-{
- public function __toString() {
- return "Class A object";
- }
-}
-
-// heredoc string
-$heredoc = <<<EOT
-hello world
-EOT;
-
-// get a resource variable
-$fp = fopen(__FILE__, "r");
-
-// unexpected values to be passed to $stack argument
-$inputs = array(
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 12.3456789000e10,
- 12.3456789000E-10,
- .5,
-
- // null data
-/*10*/ NULL,
- null,
-
- // boolean data
-/*12*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*16*/ "",
- '',
-
- // string data
-/*18*/ "string",
- 'string',
- $heredoc,
-
- // object data
-/*21*/ new classA(),
-
- // undefined data
-/*22*/ @$undefined_var,
-
- // unset data
-/*23*/ @$unset_var,
-
- // resource variable
-/*24*/ $fp
-);
-
-// loop through each element of $inputs to check the behavior of array_shift()
-$iterator = 1;
-foreach($inputs as $input) {
- echo "\n-- Iteration $iterator --\n";
- var_dump( array_shift($input) );
- $iterator++;
-};
-
-fclose($fp);
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing array_shift() : usage variations ***
-
--- Iteration 1 --
-
-Warning: array_shift() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 2 --
-
-Warning: array_shift() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 3 --
-
-Warning: array_shift() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 4 --
-
-Warning: array_shift() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 5 --
-
-Warning: array_shift() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 6 --
-
-Warning: array_shift() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 7 --
-
-Warning: array_shift() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 8 --
-
-Warning: array_shift() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 9 --
-
-Warning: array_shift() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 10 --
-
-Warning: array_shift() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 11 --
-
-Warning: array_shift() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 12 --
-
-Warning: array_shift() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 13 --
-
-Warning: array_shift() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 14 --
-
-Warning: array_shift() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 15 --
-
-Warning: array_shift() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 16 --
-
-Warning: array_shift() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 17 --
-
-Warning: array_shift() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 18 --
-
-Warning: array_shift() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 19 --
-
-Warning: array_shift() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 20 --
-
-Warning: array_shift() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 21 --
-
-Warning: array_shift() expects parameter 1 to be array, object given in %s on line %d
-NULL
-
--- Iteration 22 --
-
-Warning: array_shift() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 23 --
-
-Warning: array_shift() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 24 --
-
-Warning: array_shift() expects parameter 1 to be array, resource given in %s on line 85
-NULL
-Done
diff --git a/ext/standard/tests/array/array_slice_variation4.phpt b/ext/standard/tests/array/array_slice_variation4.phpt
deleted file mode 100644
index 6591e113af..0000000000
--- a/ext/standard/tests/array/array_slice_variation4.phpt
+++ /dev/null
@@ -1,326 +0,0 @@
---TEST--
-Test array_slice() function : usage variations - Pass different data types as $preserve_keys arg
---FILE--
-<?php
-/* Prototype : array array_slice(array $input, int $offset [, int $length [, bool $preserve_keys]])
- * Description: Returns elements specified by offset and length
- * Source code: ext/standard/array.c
- */
-
-/*
- * Pass different data types as $preserve_keys argument to array_slice() to test behaviour
- */
-
-echo "*** Testing array_slice() : usage variations ***\n";
-
-// Initialise function arguments not being substituted
-$input_array = array('one' => 1, 2, 99 => 3, 4);
-$offset = 0;
-$length = 3;
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// get a class
-class classA
-{
- public function __toString() {
- return "Class A object";
- }
-}
-
-// heredoc string
-$heredoc = <<<EOT
-hello world
-EOT;
-
-// unexpected values to be passed to $preserve_keys argument
-$inputs = array(
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 12.3456789000e10,
- 12.3456789000E-10,
- .5,
-
- // null data
-/*10*/ NULL,
- null,
-
- // boolean data
-/*12*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*16*/ "",
- '',
- array(),
-
- // string data
-/*19*/ "string",
- 'string',
- $heredoc,
-
- // object data
-/*22*/ new classA(),
-
- // undefined data
-/*23*/ @$undefined_var,
-
- // unset data
-/*24*/ @$unset_var,
-);
-
-// loop through each element of $inputs to check the behavior of array_slice()
-$iterator = 1;
-foreach($inputs as $input) {
- echo "\n-- Iteration $iterator --\n";
- var_dump( array_slice($input_array, $offset, $length, $input) );
- $iterator++;
-};
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing array_slice() : usage variations ***
-
--- Iteration 1 --
-array(3) {
- ["one"]=>
- int(1)
- [0]=>
- int(2)
- [1]=>
- int(3)
-}
-
--- Iteration 2 --
-array(3) {
- ["one"]=>
- int(1)
- [0]=>
- int(2)
- [99]=>
- int(3)
-}
-
--- Iteration 3 --
-array(3) {
- ["one"]=>
- int(1)
- [0]=>
- int(2)
- [99]=>
- int(3)
-}
-
--- Iteration 4 --
-array(3) {
- ["one"]=>
- int(1)
- [0]=>
- int(2)
- [99]=>
- int(3)
-}
-
--- Iteration 5 --
-array(3) {
- ["one"]=>
- int(1)
- [0]=>
- int(2)
- [99]=>
- int(3)
-}
-
--- Iteration 6 --
-array(3) {
- ["one"]=>
- int(1)
- [0]=>
- int(2)
- [99]=>
- int(3)
-}
-
--- Iteration 7 --
-array(3) {
- ["one"]=>
- int(1)
- [0]=>
- int(2)
- [99]=>
- int(3)
-}
-
--- Iteration 8 --
-array(3) {
- ["one"]=>
- int(1)
- [0]=>
- int(2)
- [99]=>
- int(3)
-}
-
--- Iteration 9 --
-array(3) {
- ["one"]=>
- int(1)
- [0]=>
- int(2)
- [99]=>
- int(3)
-}
-
--- Iteration 10 --
-array(3) {
- ["one"]=>
- int(1)
- [0]=>
- int(2)
- [1]=>
- int(3)
-}
-
--- Iteration 11 --
-array(3) {
- ["one"]=>
- int(1)
- [0]=>
- int(2)
- [1]=>
- int(3)
-}
-
--- Iteration 12 --
-array(3) {
- ["one"]=>
- int(1)
- [0]=>
- int(2)
- [99]=>
- int(3)
-}
-
--- Iteration 13 --
-array(3) {
- ["one"]=>
- int(1)
- [0]=>
- int(2)
- [1]=>
- int(3)
-}
-
--- Iteration 14 --
-array(3) {
- ["one"]=>
- int(1)
- [0]=>
- int(2)
- [99]=>
- int(3)
-}
-
--- Iteration 15 --
-array(3) {
- ["one"]=>
- int(1)
- [0]=>
- int(2)
- [1]=>
- int(3)
-}
-
--- Iteration 16 --
-array(3) {
- ["one"]=>
- int(1)
- [0]=>
- int(2)
- [1]=>
- int(3)
-}
-
--- Iteration 17 --
-array(3) {
- ["one"]=>
- int(1)
- [0]=>
- int(2)
- [1]=>
- int(3)
-}
-
--- Iteration 18 --
-
-Warning: array_slice() expects parameter 4 to be bool, array given in %s on line %d
-NULL
-
--- Iteration 19 --
-array(3) {
- ["one"]=>
- int(1)
- [0]=>
- int(2)
- [99]=>
- int(3)
-}
-
--- Iteration 20 --
-array(3) {
- ["one"]=>
- int(1)
- [0]=>
- int(2)
- [99]=>
- int(3)
-}
-
--- Iteration 21 --
-array(3) {
- ["one"]=>
- int(1)
- [0]=>
- int(2)
- [99]=>
- int(3)
-}
-
--- Iteration 22 --
-
-Warning: array_slice() expects parameter 4 to be bool, object given in %s on line %d
-NULL
-
--- Iteration 23 --
-array(3) {
- ["one"]=>
- int(1)
- [0]=>
- int(2)
- [1]=>
- int(3)
-}
-
--- Iteration 24 --
-array(3) {
- ["one"]=>
- int(1)
- [0]=>
- int(2)
- [1]=>
- int(3)
-}
-Done
diff --git a/ext/standard/tests/array/array_sum_variation1.phpt b/ext/standard/tests/array/array_sum_variation1.phpt
deleted file mode 100644
index 30e2847004..0000000000
--- a/ext/standard/tests/array/array_sum_variation1.phpt
+++ /dev/null
@@ -1,179 +0,0 @@
---TEST--
-Test array_sum() function : usage variations - unexpected values for 'input' argument
---FILE--
-<?php
-/* Prototype : mixed array_sum(array $input)
- * Description: Returns the sum of the array entries
- * Source code: ext/standard/array.c
-*/
-
-/*
-* Passing different scalar/nonscalar values as 'input' argument to array_sum()
-*/
-
-echo "*** Testing array_sum() : unexpected values for 'input' ***\n";
-
-// get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// Class definition
-class MyClass
-{
- public function __toString()
- {
- return "object";
- }
-}
-
-// different scalar/non scalar values for 'input' argument
-$input_values = array(
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 10.1234567e8,
- 10.7654321E-8,
- .5,
-
- // null data
-/*10*/ NULL,
- null,
-
- // boolean data
-/*12*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*16*/ "",
- '',
-
- // string data
-/*18*/ "string",
- 'string',
-
- // object data
-/*20*/ new MyClass(),
-
- // resource data
-/*21*/ $fp = fopen(__FILE__,'r'),
-
- // undefined data
-/*22*/ @$undefined_var,
-
- // unset data
-/*23*/ @$unset_var,
-);
-
-// loop through each element of the array for input
-for($count = 0; $count < count($input_values); $count++) {
- echo "-- Iteration ".($count + 1)." --\n";
- var_dump( array_sum($input_values[$count]) );
-};
-
-fclose($fp);
-echo "Done"
-?>
---EXPECTF--
-*** Testing array_sum() : unexpected values for 'input' ***
--- Iteration 1 --
-
-Warning: array_sum() expects parameter 1 to be array, int given in %s on line %d
-NULL
--- Iteration 2 --
-
-Warning: array_sum() expects parameter 1 to be array, int given in %s on line %d
-NULL
--- Iteration 3 --
-
-Warning: array_sum() expects parameter 1 to be array, int given in %s on line %d
-NULL
--- Iteration 4 --
-
-Warning: array_sum() expects parameter 1 to be array, int given in %s on line %d
-NULL
--- Iteration 5 --
-
-Warning: array_sum() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 6 --
-
-Warning: array_sum() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 7 --
-
-Warning: array_sum() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 8 --
-
-Warning: array_sum() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 9 --
-
-Warning: array_sum() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 10 --
-
-Warning: array_sum() expects parameter 1 to be array, null given in %s on line %d
-NULL
--- Iteration 11 --
-
-Warning: array_sum() expects parameter 1 to be array, null given in %s on line %d
-NULL
--- Iteration 12 --
-
-Warning: array_sum() expects parameter 1 to be array, bool given in %s on line %d
-NULL
--- Iteration 13 --
-
-Warning: array_sum() expects parameter 1 to be array, bool given in %s on line %d
-NULL
--- Iteration 14 --
-
-Warning: array_sum() expects parameter 1 to be array, bool given in %s on line %d
-NULL
--- Iteration 15 --
-
-Warning: array_sum() expects parameter 1 to be array, bool given in %s on line %d
-NULL
--- Iteration 16 --
-
-Warning: array_sum() expects parameter 1 to be array, string given in %s on line %d
-NULL
--- Iteration 17 --
-
-Warning: array_sum() expects parameter 1 to be array, string given in %s on line %d
-NULL
--- Iteration 18 --
-
-Warning: array_sum() expects parameter 1 to be array, string given in %s on line %d
-NULL
--- Iteration 19 --
-
-Warning: array_sum() expects parameter 1 to be array, string given in %s on line %d
-NULL
--- Iteration 20 --
-
-Warning: array_sum() expects parameter 1 to be array, object given in %s on line %d
-NULL
--- Iteration 21 --
-
-Warning: array_sum() expects parameter 1 to be array, resource given in %s on line %d
-NULL
--- Iteration 22 --
-
-Warning: array_sum() expects parameter 1 to be array, null given in %s on line %d
-NULL
--- Iteration 23 --
-
-Warning: array_sum() expects parameter 1 to be array, null given in %s on line %d
-NULL
-Done
diff --git a/ext/standard/tests/array/array_unique_variation1.phpt b/ext/standard/tests/array/array_unique_variation1.phpt
deleted file mode 100644
index cc9a695c86..0000000000
--- a/ext/standard/tests/array/array_unique_variation1.phpt
+++ /dev/null
@@ -1,195 +0,0 @@
---TEST--
-Test array_unique() function : usage variations - unexpected values for 'input' argument
---FILE--
-<?php
-/* Prototype : array array_unique(array $input)
- * Description: Removes duplicate values from array
- * Source code: ext/standard/array.c
-*/
-
-/*
- * Passing non array values to 'input' argument of array_unique() and see
- * that the function outputs proper warning messages wherever expected.
-*/
-
-echo "*** Testing array_unique() : Passing non array values to \$input argument ***\n";
-
-//get an unset variable
-$unset_var = 10;
-unset($unset_var);
-
-// get a class
-class classA
-{
- public function __toString() {
- return "Class A object";
- }
-}
-
-// heredoc string
-$heredoc = <<<EOT
-hello world
-EOT;
-
-// get a resource variable
-$fp = fopen(__FILE__, "r");
-
-// unexpected values to be passed to $input argument
-$inputs = array (
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 12.3456789000e10,
- 12.3456789000E-10,
- .5,
-
- // null data
-/*10*/ NULL,
- null,
-
- // boolean data
-/*12*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*16*/ "",
- '',
-
- // string data
-/*18*/ "string",
- 'string',
- $heredoc,
-
- // object data
-/*21*/ new classA(),
-
- // undefined data
-/*22*/ @$undefined_var,
-
- // unset data
-/*23*/ @$unset_var,
-
- // resource variable
-/*24*/ $fp
-);
-
-// loop through each element of $inputs and check the behavior of array_unique()
-$iterator = 1;
-foreach($inputs as $input) {
- echo "-- Iteration $iterator --\n";
- var_dump( array_unique($input) );
- $iterator++;
-}
-
-fclose($fp);
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing array_unique() : Passing non array values to $input argument ***
--- Iteration 1 --
-
-Warning: array_unique() expects parameter 1 to be array, int given in %s on line %d
-NULL
--- Iteration 2 --
-
-Warning: array_unique() expects parameter 1 to be array, int given in %s on line %d
-NULL
--- Iteration 3 --
-
-Warning: array_unique() expects parameter 1 to be array, int given in %s on line %d
-NULL
--- Iteration 4 --
-
-Warning: array_unique() expects parameter 1 to be array, int given in %s on line %d
-NULL
--- Iteration 5 --
-
-Warning: array_unique() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 6 --
-
-Warning: array_unique() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 7 --
-
-Warning: array_unique() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 8 --
-
-Warning: array_unique() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 9 --
-
-Warning: array_unique() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 10 --
-
-Warning: array_unique() expects parameter 1 to be array, null given in %s on line %d
-NULL
--- Iteration 11 --
-
-Warning: array_unique() expects parameter 1 to be array, null given in %s on line %d
-NULL
--- Iteration 12 --
-
-Warning: array_unique() expects parameter 1 to be array, bool given in %s on line %d
-NULL
--- Iteration 13 --
-
-Warning: array_unique() expects parameter 1 to be array, bool given in %s on line %d
-NULL
--- Iteration 14 --
-
-Warning: array_unique() expects parameter 1 to be array, bool given in %s on line %d
-NULL
--- Iteration 15 --
-
-Warning: array_unique() expects parameter 1 to be array, bool given in %s on line %d
-NULL
--- Iteration 16 --
-
-Warning: array_unique() expects parameter 1 to be array, string given in %s on line %d
-NULL
--- Iteration 17 --
-
-Warning: array_unique() expects parameter 1 to be array, string given in %s on line %d
-NULL
--- Iteration 18 --
-
-Warning: array_unique() expects parameter 1 to be array, string given in %s on line %d
-NULL
--- Iteration 19 --
-
-Warning: array_unique() expects parameter 1 to be array, string given in %s on line %d
-NULL
--- Iteration 20 --
-
-Warning: array_unique() expects parameter 1 to be array, string given in %s on line %d
-NULL
--- Iteration 21 --
-
-Warning: array_unique() expects parameter 1 to be array, object given in %s on line %d
-NULL
--- Iteration 22 --
-
-Warning: array_unique() expects parameter 1 to be array, null given in %s on line %d
-NULL
--- Iteration 23 --
-
-Warning: array_unique() expects parameter 1 to be array, null given in %s on line %d
-NULL
--- Iteration 24 --
-
-Warning: array_unique() expects parameter 1 to be array, resource given in %s on line %d
-NULL
-Done
diff --git a/ext/standard/tests/array/array_unshift_variation1.phpt b/ext/standard/tests/array/array_unshift_variation1.phpt
deleted file mode 100644
index f80fc0ebc6..0000000000
--- a/ext/standard/tests/array/array_unshift_variation1.phpt
+++ /dev/null
@@ -1,338 +0,0 @@
---TEST--
-Test array_unshift() function : usage variations - unexpected values for 'array' argument
---FILE--
-<?php
-/* Prototype : int array_unshift(array $array, mixed $var [, mixed ...])
- * Description: Pushes elements onto the beginning of the array
- * Source code: ext/standard/array.c
-*/
-
-/*
- * Testing the behavior of array_unshift() by giving values
- * other than array values for $array argument
-*/
-
-echo "*** Testing array_unshift() : unexpected values for \$array argument ***\n";
-
-// Initialise $var argument
-$var = 12;
-
-// get a class
-class classA
-{
- public function __toString() {
- return "Class A object";
- }
-}
-
-// heredoc string
-$heredoc = <<<EOT
-hello world
-EOT;
-
-// get a resource variable
-$fp = fopen(__FILE__, "r");
-
-// get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// array of unexpected values to be passed to $array argument
-$arrays = array(
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 12.3456789000e10,
- 12.3456789000E-10,
- .5,
-
- // null data
-/*10*/ NULL,
- null,
-
- // boolean data
-/*12*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*16*/ "",
- '',
-
- // string data
-/*18*/ "string",
- 'string',
- $heredoc,
-
- // object data
-/*21*/ new classA(),
-
- // undefined data
- @$undefined_var,
-
- // unset data
- @$unset_var,
-
- // resource variable
-/*24*/ $fp
-);
-
-// loop through each element of $arrays to test the functionality of array_unshift()
-$iterator = 1;
-foreach($arrays as $array) {
- echo "\n-- Iteration $iterator --";
-
- /* with default arguments */
- // returns element count in the resulting array after arguments are pushed to
- // beginning of the given array
- $temp_array = $array;
- var_dump( array_unshift($temp_array, $var) );
-
- // dump the resulting array
- var_dump($temp_array);
-
- /* with optional arguments */
- // returns element count in the resulting array after arguments are pushed to
- // beginning of the given array
- $temp_array = $array;
- var_dump( array_unshift($temp_array, $var, "hello", 'world') );
-
- // dump the resulting array
- var_dump($temp_array);
- $iterator++;
-};
-
-// close the file resource used
-fclose($fp);
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing array_unshift() : unexpected values for $array argument ***
-
--- Iteration 1 --
-Warning: array_unshift() expects parameter 1 to be array, int given in %s on line %d
-NULL
-int(0)
-
-Warning: array_unshift() expects parameter 1 to be array, int given in %s on line %d
-NULL
-int(0)
-
--- Iteration 2 --
-Warning: array_unshift() expects parameter 1 to be array, int given in %s on line %d
-NULL
-int(1)
-
-Warning: array_unshift() expects parameter 1 to be array, int given in %s on line %d
-NULL
-int(1)
-
--- Iteration 3 --
-Warning: array_unshift() expects parameter 1 to be array, int given in %s on line %d
-NULL
-int(12345)
-
-Warning: array_unshift() expects parameter 1 to be array, int given in %s on line %d
-NULL
-int(12345)
-
--- Iteration 4 --
-Warning: array_unshift() expects parameter 1 to be array, int given in %s on line %d
-NULL
-int(-2345)
-
-Warning: array_unshift() expects parameter 1 to be array, int given in %s on line %d
-NULL
-int(-2345)
-
--- Iteration 5 --
-Warning: array_unshift() expects parameter 1 to be array, float given in %s on line %d
-NULL
-float(10.5)
-
-Warning: array_unshift() expects parameter 1 to be array, float given in %s on line %d
-NULL
-float(10.5)
-
--- Iteration 6 --
-Warning: array_unshift() expects parameter 1 to be array, float given in %s on line %d
-NULL
-float(-10.5)
-
-Warning: array_unshift() expects parameter 1 to be array, float given in %s on line %d
-NULL
-float(-10.5)
-
--- Iteration 7 --
-Warning: array_unshift() expects parameter 1 to be array, float given in %s on line %d
-NULL
-float(123456789000)
-
-Warning: array_unshift() expects parameter 1 to be array, float given in %s on line %d
-NULL
-float(123456789000)
-
--- Iteration 8 --
-Warning: array_unshift() expects parameter 1 to be array, float given in %s on line %d
-NULL
-float(1.23456789E-9)
-
-Warning: array_unshift() expects parameter 1 to be array, float given in %s on line %d
-NULL
-float(1.23456789E-9)
-
--- Iteration 9 --
-Warning: array_unshift() expects parameter 1 to be array, float given in %s on line %d
-NULL
-float(0.5)
-
-Warning: array_unshift() expects parameter 1 to be array, float given in %s on line %d
-NULL
-float(0.5)
-
--- Iteration 10 --
-Warning: array_unshift() expects parameter 1 to be array, null given in %s on line %d
-NULL
-NULL
-
-Warning: array_unshift() expects parameter 1 to be array, null given in %s on line %d
-NULL
-NULL
-
--- Iteration 11 --
-Warning: array_unshift() expects parameter 1 to be array, null given in %s on line %d
-NULL
-NULL
-
-Warning: array_unshift() expects parameter 1 to be array, null given in %s on line %d
-NULL
-NULL
-
--- Iteration 12 --
-Warning: array_unshift() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-bool(true)
-
-Warning: array_unshift() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-bool(true)
-
--- Iteration 13 --
-Warning: array_unshift() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-bool(false)
-
-Warning: array_unshift() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-bool(false)
-
--- Iteration 14 --
-Warning: array_unshift() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-bool(true)
-
-Warning: array_unshift() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-bool(true)
-
--- Iteration 15 --
-Warning: array_unshift() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-bool(false)
-
-Warning: array_unshift() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-bool(false)
-
--- Iteration 16 --
-Warning: array_unshift() expects parameter 1 to be array, string given in %s on line %d
-NULL
-string(0) ""
-
-Warning: array_unshift() expects parameter 1 to be array, string given in %s on line %d
-NULL
-string(0) ""
-
--- Iteration 17 --
-Warning: array_unshift() expects parameter 1 to be array, string given in %s on line %d
-NULL
-string(0) ""
-
-Warning: array_unshift() expects parameter 1 to be array, string given in %s on line %d
-NULL
-string(0) ""
-
--- Iteration 18 --
-Warning: array_unshift() expects parameter 1 to be array, string given in %s on line %d
-NULL
-string(6) "string"
-
-Warning: array_unshift() expects parameter 1 to be array, string given in %s on line %d
-NULL
-string(6) "string"
-
--- Iteration 19 --
-Warning: array_unshift() expects parameter 1 to be array, string given in %s on line %d
-NULL
-string(6) "string"
-
-Warning: array_unshift() expects parameter 1 to be array, string given in %s on line %d
-NULL
-string(6) "string"
-
--- Iteration 20 --
-Warning: array_unshift() expects parameter 1 to be array, string given in %s on line %d
-NULL
-string(11) "hello world"
-
-Warning: array_unshift() expects parameter 1 to be array, string given in %s on line %d
-NULL
-string(11) "hello world"
-
--- Iteration 21 --
-Warning: array_unshift() expects parameter 1 to be array, object given in %s on line %d
-NULL
-object(classA)#1 (0) {
-}
-
-Warning: array_unshift() expects parameter 1 to be array, object given in %s on line %d
-NULL
-object(classA)#1 (0) {
-}
-
--- Iteration 22 --
-Warning: array_unshift() expects parameter 1 to be array, null given in %s on line %d
-NULL
-NULL
-
-Warning: array_unshift() expects parameter 1 to be array, null given in %s on line %d
-NULL
-NULL
-
--- Iteration 23 --
-Warning: array_unshift() expects parameter 1 to be array, null given in %s on line %d
-NULL
-NULL
-
-Warning: array_unshift() expects parameter 1 to be array, null given in %s on line %d
-NULL
-NULL
-
--- Iteration 24 --
-Warning: array_unshift() expects parameter 1 to be array, resource given in %s on line %d
-NULL
-resource(%d) of type (stream)
-
-Warning: array_unshift() expects parameter 1 to be array, resource given in %s on line %d
-NULL
-resource(%d) of type (stream)
-Done
diff --git a/ext/standard/tests/array/array_values_variation1.phpt b/ext/standard/tests/array/array_values_variation1.phpt
deleted file mode 100644
index 0ee93e2a12..0000000000
--- a/ext/standard/tests/array/array_values_variation1.phpt
+++ /dev/null
@@ -1,223 +0,0 @@
---TEST--
-Test array_values() function : usage variations - Pass different data types as $input arg
---FILE--
-<?php
-/* Prototype : array array_values(array $input)
- * Description: Return just the values from the input array
- * Source code: ext/standard/array.c
- */
-
-/*
- * Pass different data types as $input argument to array_values() to test behaviour
- */
-
-echo "*** Testing array_values() : usage variations ***\n";
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// get a class
-class classA
-{
- public function __toString() {
- return "Class A object";
- }
-}
-
-// heredoc string
-$heredoc = <<<EOT
-hello world
-EOT;
-
-// get a resource variable
-$fp = fopen(__FILE__, "r");
-
-// unexpected values to be passed to $input argument
-$inputs = array(
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 12.3456789000e10,
- 12.3456789000E-10,
- .5,
-
- // null data
-/*10*/ NULL,
- null,
-
- // boolean data
-/*12*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*16*/ "",
- '',
- array(),
-
- // string data
-/*19*/ "string",
- 'string',
- $heredoc,
-
- // object data
-/*22*/ new classA(),
-
- // undefined data
-/*23*/ @$undefined_var,
-
- // unset data
-/*24*/ @$unset_var,
-
- // resource variable
-/*25*/ $fp
-);
-
-// loop through each element of $inputs to check the behavior of array_values()
-$iterator = 1;
-foreach($inputs as $input) {
- echo "\n-- Iteration $iterator --\n";
- var_dump( array_values($input) );
- $iterator++;
-};
-
-fclose($fp);
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing array_values() : usage variations ***
-
--- Iteration 1 --
-
-Warning: array_values() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 2 --
-
-Warning: array_values() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 3 --
-
-Warning: array_values() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 4 --
-
-Warning: array_values() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 5 --
-
-Warning: array_values() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 6 --
-
-Warning: array_values() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 7 --
-
-Warning: array_values() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 8 --
-
-Warning: array_values() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 9 --
-
-Warning: array_values() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 10 --
-
-Warning: array_values() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 11 --
-
-Warning: array_values() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 12 --
-
-Warning: array_values() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 13 --
-
-Warning: array_values() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 14 --
-
-Warning: array_values() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 15 --
-
-Warning: array_values() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 16 --
-
-Warning: array_values() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 17 --
-
-Warning: array_values() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 18 --
-array(0) {
-}
-
--- Iteration 19 --
-
-Warning: array_values() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 20 --
-
-Warning: array_values() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 21 --
-
-Warning: array_values() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 22 --
-
-Warning: array_values() expects parameter 1 to be array, object given in %s on line %d
-NULL
-
--- Iteration 23 --
-
-Warning: array_values() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 24 --
-
-Warning: array_values() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 25 --
-
-Warning: array_values() expects parameter 1 to be array, resource given in %s on line %d
-NULL
-Done
diff --git a/ext/standard/tests/array/array_walk_recursive_variation1.phpt b/ext/standard/tests/array/array_walk_recursive_variation1.phpt
deleted file mode 100644
index 56abaca83d..0000000000
--- a/ext/standard/tests/array/array_walk_recursive_variation1.phpt
+++ /dev/null
@@ -1,250 +0,0 @@
---TEST--
-Test array_walk_recursive() function : usage variations - unexpected values for 'input' argument
---FILE--
-<?php
-/* Prototype : bool array_walk_recursive(array $input, string $funcname [, mixed $userdata])
- * Description: Apply a user function to every member of an array
- * Source code: ext/standard/array.c
-*/
-
-/*
- * Passing different scalar/nonscalar values in place of 'input' argument
-*/
-
-echo "*** Testing array_walk_recursive() : unexpected values for 'input' argument ***\n";
-
-// callback function
-/* Prototype : callback(mixed $value, mixed $key)
- * Parameters : $value - values given in input array
- * $key - keys given in input array
- * Description : Function prints each element of an array with key
- */
-function callback($value, $key)
-{
- echo "key : ";
- var_dump($key);
- echo "value : ";
- var_dump($value);
-}
-
-// extra parameter passed to array_walk_recursive()
-$user_data = 10;
-
-// get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// get resource variable
-$fp = fopen(__FILE__, 'r');
-
-// different scalar/nonscalar values to be used in place of an 'input' argument
-$input_values = array(
-
- // int data
-/* 1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/* 5*/ 10.5,
- -10.5,
- 10.1234567e8,
- 10.7654321E-8,
- .5,
-
- // null data
-/* 10*/ NULL,
- null,
-
- // boolean data
-/* 12*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/* 16*/ "",
- '',
-
- // string data
-/* 18*/ "string",
- 'string',
-
- // resource data
- $fp,
-
- // undefined data
- @$undefined_var,
-
- // unset data
-/* 22*/ @$unset_var,
-);
-
-
-for($count = 0; $count < count($input_values); $count++) {
- echo "-- Iteration ".($count + 1)." --\n";
- var_dump( array_walk_recursive($input_values[$count], "callback") );
- var_dump( array_walk_recursive($input_values[$count], "callback", $user_data) );
-}
-
-fclose($fp);
-echo "Done"
-?>
---EXPECTF--
-*** Testing array_walk_recursive() : unexpected values for 'input' argument ***
--- Iteration 1 --
-
-Warning: array_walk_recursive() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 1 to be array, int given in %s on line %d
-NULL
--- Iteration 2 --
-
-Warning: array_walk_recursive() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 1 to be array, int given in %s on line %d
-NULL
--- Iteration 3 --
-
-Warning: array_walk_recursive() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 1 to be array, int given in %s on line %d
-NULL
--- Iteration 4 --
-
-Warning: array_walk_recursive() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 1 to be array, int given in %s on line %d
-NULL
--- Iteration 5 --
-
-Warning: array_walk_recursive() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 6 --
-
-Warning: array_walk_recursive() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 7 --
-
-Warning: array_walk_recursive() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 8 --
-
-Warning: array_walk_recursive() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 9 --
-
-Warning: array_walk_recursive() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 10 --
-
-Warning: array_walk_recursive() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 1 to be array, null given in %s on line %d
-NULL
--- Iteration 11 --
-
-Warning: array_walk_recursive() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 1 to be array, null given in %s on line %d
-NULL
--- Iteration 12 --
-
-Warning: array_walk_recursive() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 1 to be array, bool given in %s on line %d
-NULL
--- Iteration 13 --
-
-Warning: array_walk_recursive() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 1 to be array, bool given in %s on line %d
-NULL
--- Iteration 14 --
-
-Warning: array_walk_recursive() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 1 to be array, bool given in %s on line %d
-NULL
--- Iteration 15 --
-
-Warning: array_walk_recursive() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 1 to be array, bool given in %s on line %d
-NULL
--- Iteration 16 --
-
-Warning: array_walk_recursive() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 1 to be array, string given in %s on line %d
-NULL
--- Iteration 17 --
-
-Warning: array_walk_recursive() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 1 to be array, string given in %s on line %d
-NULL
--- Iteration 18 --
-
-Warning: array_walk_recursive() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 1 to be array, string given in %s on line %d
-NULL
--- Iteration 19 --
-
-Warning: array_walk_recursive() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 1 to be array, string given in %s on line %d
-NULL
--- Iteration 20 --
-
-Warning: array_walk_recursive() expects parameter 1 to be array, resource given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 1 to be array, resource given in %s on line %d
-NULL
--- Iteration 21 --
-
-Warning: array_walk_recursive() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 1 to be array, null given in %s on line %d
-NULL
--- Iteration 22 --
-
-Warning: array_walk_recursive() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 1 to be array, null given in %s on line %d
-NULL
-Done
diff --git a/ext/standard/tests/array/array_walk_recursive_variation2.phpt b/ext/standard/tests/array/array_walk_recursive_variation2.phpt
deleted file mode 100644
index 5c8c56dcc2..0000000000
--- a/ext/standard/tests/array/array_walk_recursive_variation2.phpt
+++ /dev/null
@@ -1,268 +0,0 @@
---TEST--
-Test array_walk_recursive() function : usage variations - unexpected values in place of 'funcname' argument
---FILE--
-<?php
-/* Prototype : bool array_walk_recursive(array $input, string $funcname [, mixed $userdata])
- * Description: Apply a user function to every member of an array
- * Source code: ext/standard/array.c
-*/
-
-/*
- * Passing different scalar/nonscalar values in place of 'funcname' argument
-*/
-
-echo "*** Testing array_walk_recursive() : unexpected values for 'funcname' argument ***\n";
-
-$input = array(1, array(2, 3));
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-$user_data = 20;
-
-// class definition
-class MyClass
-{
- public function __toString()
- {
- return 'object';
- }
-}
-
-// different scalar/nonscalar values to be used in place of callback function
-$funcname_values = array(
-
- // int data
-/* 1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/* 5*/ 10.5,
- -10.5,
- 10.1234567e8,
- 10.7654321E-8,
- .5,
-
- // array data
-/* 10*/ array(),
- array(0),
- array(1),
- array('color' => 'red', 'item' => 'pen'),
-
- // null data
-/* 14*/ NULL,
- null,
-
- // boolean data
-/* 16*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/* 20*/ "",
- '',
-
- // object data
- new MyClass(),
-
- // resource data
-/* 23*/ $fp = fopen(__FILE__, 'r'),
-
- // undefined data
- @$undefined_var,
-
- // unset data
-/* 25*/ @$unset_var,
-);
-
-for($count = 0; $count < count($funcname_values); $count++) {
- echo "-- Iteration ".($count + 1)." --\n";
- var_dump( array_walk_recursive($input, $funcname_values[$count]) );
- var_dump( array_walk_recursive($input, $funcname_values[$count], $user_data ));
-}
-
-fclose($fp);
-echo "Done"
-?>
---EXPECTF--
-*** Testing array_walk_recursive() : unexpected values for 'funcname' argument ***
--- Iteration 1 --
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 2 --
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 3 --
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 4 --
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 5 --
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 6 --
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 7 --
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 8 --
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 9 --
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 10 --
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, array must have exactly two members in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, array must have exactly two members in %s on line %d
-NULL
--- Iteration 11 --
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, array must have exactly two members in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, array must have exactly two members in %s on line %d
-NULL
--- Iteration 12 --
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, array must have exactly two members in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, array must have exactly two members in %s on line %d
-NULL
--- Iteration 13 --
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, first array member is not a valid class name or object in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, first array member is not a valid class name or object in %s on line %d
-NULL
--- Iteration 14 --
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 15 --
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 16 --
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 17 --
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 18 --
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 19 --
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 20 --
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, function '' not found or invalid function name in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, function '' not found or invalid function name in %s on line %d
-NULL
--- Iteration 21 --
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, function '' not found or invalid function name in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, function '' not found or invalid function name in %s on line %d
-NULL
--- Iteration 22 --
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 23 --
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 24 --
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 25 --
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-Done
diff --git a/ext/standard/tests/array/array_walk_variation1.phpt b/ext/standard/tests/array/array_walk_variation1.phpt
deleted file mode 100644
index 5fc3e62f2a..0000000000
--- a/ext/standard/tests/array/array_walk_variation1.phpt
+++ /dev/null
@@ -1,250 +0,0 @@
---TEST--
-Test array_walk() function : usage variations - unexpected values for 'input' argument
---FILE--
-<?php
-/* Prototype : bool array_walk(array $input, string $funcname [, mixed $userdata])
- * Description: Apply a user function to every member of an array
- * Source code: ext/standard/array.c
-*/
-
-/*
- * Passing different scalar/nonscalar values in place of 'input' argument
-*/
-
-echo "*** Testing array_walk() : unexpected values for 'input' argument ***\n";
-
-// callback function
-/* Prototype : callback(mixed $value, mixed $key)
- * Parameters : $value - values given in input array
- * $key - keys given in input array
- * Description : Function prints each element of an array with key
- */
-function callback($value, $key)
-{
- echo "key : ";
- var_dump($key);
- echo "value : ";
- var_dump($value);
-}
-
-// extra parameter passed to array_walk()
-$user_data = 10;
-
-// get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// get resource variable
-$fp = fopen(__FILE__, 'r');
-
-// different scalar/nonscalar values to be used in place of an 'input' argument
-$input_values = array(
-
- // int data
-/* 1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/* 5*/ 10.5,
- -10.5,
- 10.1234567e8,
- 10.7654321E-8,
- .5,
-
- // null data
-/* 10*/ NULL,
- null,
-
- // boolean data
-/* 12*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/* 16*/ "",
- '',
-
- // string data
-/* 18*/ "string",
- 'string',
-
- // resource data
- $fp,
-
- // undefined data
- @$undefined_var,
-
- // unset data
-/* 22*/ @$unset_var,
-);
-
-
-for($count = 0; $count < count($input_values); $count++) {
- echo "-- Iteration ".($count + 1)." --\n";
- var_dump( array_walk($input_values[$count], "callback") );
- var_dump( array_walk($input_values[$count], "callback", $user_data) );
-}
-
-fclose($fp);
-echo "Done"
-?>
---EXPECTF--
-*** Testing array_walk() : unexpected values for 'input' argument ***
--- Iteration 1 --
-
-Warning: array_walk() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 1 to be array, int given in %s on line %d
-NULL
--- Iteration 2 --
-
-Warning: array_walk() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 1 to be array, int given in %s on line %d
-NULL
--- Iteration 3 --
-
-Warning: array_walk() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 1 to be array, int given in %s on line %d
-NULL
--- Iteration 4 --
-
-Warning: array_walk() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 1 to be array, int given in %s on line %d
-NULL
--- Iteration 5 --
-
-Warning: array_walk() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 6 --
-
-Warning: array_walk() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 7 --
-
-Warning: array_walk() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 8 --
-
-Warning: array_walk() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 9 --
-
-Warning: array_walk() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 10 --
-
-Warning: array_walk() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 1 to be array, null given in %s on line %d
-NULL
--- Iteration 11 --
-
-Warning: array_walk() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 1 to be array, null given in %s on line %d
-NULL
--- Iteration 12 --
-
-Warning: array_walk() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 1 to be array, bool given in %s on line %d
-NULL
--- Iteration 13 --
-
-Warning: array_walk() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 1 to be array, bool given in %s on line %d
-NULL
--- Iteration 14 --
-
-Warning: array_walk() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 1 to be array, bool given in %s on line %d
-NULL
--- Iteration 15 --
-
-Warning: array_walk() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 1 to be array, bool given in %s on line %d
-NULL
--- Iteration 16 --
-
-Warning: array_walk() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 1 to be array, string given in %s on line %d
-NULL
--- Iteration 17 --
-
-Warning: array_walk() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 1 to be array, string given in %s on line %d
-NULL
--- Iteration 18 --
-
-Warning: array_walk() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 1 to be array, string given in %s on line %d
-NULL
--- Iteration 19 --
-
-Warning: array_walk() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 1 to be array, string given in %s on line %d
-NULL
--- Iteration 20 --
-
-Warning: array_walk() expects parameter 1 to be array, resource given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 1 to be array, resource given in %s on line %d
-NULL
--- Iteration 21 --
-
-Warning: array_walk() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 1 to be array, null given in %s on line %d
-NULL
--- Iteration 22 --
-
-Warning: array_walk() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 1 to be array, null given in %s on line %d
-NULL
-Done
diff --git a/ext/standard/tests/array/array_walk_variation2.phpt b/ext/standard/tests/array/array_walk_variation2.phpt
deleted file mode 100644
index 1780f66bae..0000000000
--- a/ext/standard/tests/array/array_walk_variation2.phpt
+++ /dev/null
@@ -1,268 +0,0 @@
---TEST--
-Test array_walk() function : usage variations - unexpected values in place of 'funcname' argument
---FILE--
-<?php
-/* Prototype : bool array_walk(array $input, string $funcname [, mixed $userdata])
- * Description: Apply a user function to every member of an array
- * Source code: ext/standard/array.c
-*/
-
-/*
- * Passing different scalar/nonscalar values in place of 'funcname' argument
-*/
-
-echo "*** Testing array_walk() : unexpected values for 'funcname' argument ***\n";
-
-$input = array(1, 2);
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-$user_data = 20;
-
-// class definition
-class MyClass
-{
- public function __toString()
- {
- return 'object';
- }
-}
-
-// different scalar/nonscalar values to be used in place of callback function
-$funcname_values = array(
-
- // int data
-/* 1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/* 5*/ 10.5,
- -10.5,
- 10.1234567e8,
- 10.7654321E-8,
- .5,
-
- // array data
-/* 10*/ array(),
- array(0),
- array(1),
- array('color' => 'red', 'item' => 'pen'),
-
- // null data
-/* 14*/ NULL,
- null,
-
- // boolean data
-/* 16*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/* 20*/ "",
- '',
-
- // object data
- new MyClass(),
-
- // resource data
-/* 23*/ $fp = fopen(__FILE__, 'r'),
-
- // undefined data
- @$undefined_var,
-
- // unset data
-/* 25*/ @$unset_var,
-);
-
-for($count = 0; $count < count($funcname_values); $count++) {
- echo "-- Iteration ".($count + 1)." --\n";
- var_dump( array_walk($input, $funcname_values[$count]) );
- var_dump( array_walk($input, $funcname_values[$count], $user_data ));
-}
-
-fclose($fp);
-echo "Done"
-?>
---EXPECTF--
-*** Testing array_walk() : unexpected values for 'funcname' argument ***
--- Iteration 1 --
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 2 --
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 3 --
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 4 --
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 5 --
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 6 --
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 7 --
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 8 --
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 9 --
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 10 --
-
-Warning: array_walk() expects parameter 2 to be a valid callback, array must have exactly two members in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 2 to be a valid callback, array must have exactly two members in %s on line %d
-NULL
--- Iteration 11 --
-
-Warning: array_walk() expects parameter 2 to be a valid callback, array must have exactly two members in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 2 to be a valid callback, array must have exactly two members in %s on line %d
-NULL
--- Iteration 12 --
-
-Warning: array_walk() expects parameter 2 to be a valid callback, array must have exactly two members in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 2 to be a valid callback, array must have exactly two members in %s on line %d
-NULL
--- Iteration 13 --
-
-Warning: array_walk() expects parameter 2 to be a valid callback, first array member is not a valid class name or object in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 2 to be a valid callback, first array member is not a valid class name or object in %s on line %d
-NULL
--- Iteration 14 --
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 15 --
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 16 --
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 17 --
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 18 --
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 19 --
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 20 --
-
-Warning: array_walk() expects parameter 2 to be a valid callback, function '' not found or invalid function name in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 2 to be a valid callback, function '' not found or invalid function name in %s on line %d
-NULL
--- Iteration 21 --
-
-Warning: array_walk() expects parameter 2 to be a valid callback, function '' not found or invalid function name in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 2 to be a valid callback, function '' not found or invalid function name in %s on line %d
-NULL
--- Iteration 22 --
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 23 --
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 24 --
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 25 --
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
-Warning: array_walk() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-Done
diff --git a/ext/standard/tests/array/arsort_variation1.phpt b/ext/standard/tests/array/arsort_variation1.phpt
deleted file mode 100644
index d5547efe95..0000000000
--- a/ext/standard/tests/array/arsort_variation1.phpt
+++ /dev/null
@@ -1,399 +0,0 @@
---TEST--
-Test arsort() function : usage variations - unexpected values for 'array_arg' argument
---FILE--
-<?php
-/* Prototype : bool arsort(array &array_arg [, int sort_flags])
- * Description: Sort an array and maintain index association
- Elements will be arranged from highest to lowest when this function has completed.
- * Source code: ext/standard/array.c
-*/
-
-/*
- * testing arsort() by providing different unexpected values for array argument with following flag values.
- * 1. flag value as defualt
- * 2. SORT_REGULAR - compare items normally
- * 3. SORT_NUMERIC - compare items numerically
- * 4. SORT_STRING - compare items as strings
-*/
-
-echo "*** Testing arsort() : usage variations ***\n";
-
-// get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// resource variable
-$fp = fopen(__FILE__, "r");
-
-//array of values with indices to iterate over
-$unexpected_values = array (
-
- // int data
- 0 => 0,
- 1 => 1,
- 2 => 12345,
- 3 => -2345,
-
- // float data
- 4 => 10.5,
- 5 => -10.5,
- 6 => 10.5e3,
- 7 => 10.6E-2,
- 8 => .5,
-
- // null data
- 9 => NULL,
- 10 => null,
-
- // boolean data
- 11 => true,
- 12 => false,
- 13 => TRUE,
- 14 => FALSE,
-
- // empty data
- 15 => "",
- 16 => '',
-
- // string data
- 17 => "string",
- 18 => 'string',
-
- // object data
- 19 => new stdclass(),
-
- // undefined data
- 20 => @undefined_var,
-
- // unset data
- 21 => @unset_var,
-
- // resource variable
- 22 => $fp
-
-);
-
-// loop though each element of the array and check the working of arsort()
-// when $array argument is supplied with different values from $unexpected_values
-echo "\n-- Testing arsort() by supplying different unexpected values for 'array' argument --\n";
-echo "\n-- Flag values are defualt, SORT_REGULAR, SORT_NUMERIC, SORT_STRING --\n";
-
-$counter = 1;
-for($index = 0; $index < count($unexpected_values); $index ++) {
- echo "-- Iteration $counter --\n";
- $value = $unexpected_values [$index];
- var_dump( arsort($value) ); // expecting : bool(false)
- var_dump( arsort($value, SORT_REGULAR) ); // expecting : bool(false)
- var_dump( arsort($value, SORT_NUMERIC) ); // expecting : bool(false)
- var_dump( arsort($value, SORT_STRING) ); // expecting : bool(false)
- $counter++;
-}
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing arsort() : usage variations ***
-
--- Testing arsort() by supplying different unexpected values for 'array' argument --
-
--- Flag values are defualt, SORT_REGULAR, SORT_NUMERIC, SORT_STRING --
--- Iteration 1 --
-
-Warning: arsort() expects parameter 1 to be array, int given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, int given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, int given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, int given in %sarsort_variation1.php on line %d
-bool(false)
--- Iteration 2 --
-
-Warning: arsort() expects parameter 1 to be array, int given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, int given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, int given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, int given in %sarsort_variation1.php on line %d
-bool(false)
--- Iteration 3 --
-
-Warning: arsort() expects parameter 1 to be array, int given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, int given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, int given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, int given in %sarsort_variation1.php on line %d
-bool(false)
--- Iteration 4 --
-
-Warning: arsort() expects parameter 1 to be array, int given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, int given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, int given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, int given in %sarsort_variation1.php on line %d
-bool(false)
--- Iteration 5 --
-
-Warning: arsort() expects parameter 1 to be array, float given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, float given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, float given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, float given in %sarsort_variation1.php on line %d
-bool(false)
--- Iteration 6 --
-
-Warning: arsort() expects parameter 1 to be array, float given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, float given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, float given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, float given in %sarsort_variation1.php on line %d
-bool(false)
--- Iteration 7 --
-
-Warning: arsort() expects parameter 1 to be array, float given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, float given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, float given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, float given in %sarsort_variation1.php on line %d
-bool(false)
--- Iteration 8 --
-
-Warning: arsort() expects parameter 1 to be array, float given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, float given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, float given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, float given in %sarsort_variation1.php on line %d
-bool(false)
--- Iteration 9 --
-
-Warning: arsort() expects parameter 1 to be array, float given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, float given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, float given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, float given in %sarsort_variation1.php on line %d
-bool(false)
--- Iteration 10 --
-
-Warning: arsort() expects parameter 1 to be array, null given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, null given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, null given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, null given in %sarsort_variation1.php on line %d
-bool(false)
--- Iteration 11 --
-
-Warning: arsort() expects parameter 1 to be array, null given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, null given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, null given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, null given in %sarsort_variation1.php on line %d
-bool(false)
--- Iteration 12 --
-
-Warning: arsort() expects parameter 1 to be array, bool given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, bool given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, bool given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, bool given in %sarsort_variation1.php on line %d
-bool(false)
--- Iteration 13 --
-
-Warning: arsort() expects parameter 1 to be array, bool given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, bool given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, bool given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, bool given in %sarsort_variation1.php on line %d
-bool(false)
--- Iteration 14 --
-
-Warning: arsort() expects parameter 1 to be array, bool given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, bool given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, bool given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, bool given in %sarsort_variation1.php on line %d
-bool(false)
--- Iteration 15 --
-
-Warning: arsort() expects parameter 1 to be array, bool given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, bool given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, bool given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, bool given in %sarsort_variation1.php on line %d
-bool(false)
--- Iteration 16 --
-
-Warning: arsort() expects parameter 1 to be array, string given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, string given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, string given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, string given in %sarsort_variation1.php on line %d
-bool(false)
--- Iteration 17 --
-
-Warning: arsort() expects parameter 1 to be array, string given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, string given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, string given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, string given in %sarsort_variation1.php on line %d
-bool(false)
--- Iteration 18 --
-
-Warning: arsort() expects parameter 1 to be array, string given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, string given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, string given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, string given in %sarsort_variation1.php on line %d
-bool(false)
--- Iteration 19 --
-
-Warning: arsort() expects parameter 1 to be array, string given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, string given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, string given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, string given in %sarsort_variation1.php on line %d
-bool(false)
--- Iteration 20 --
-
-Warning: arsort() expects parameter 1 to be array, object given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, object given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, object given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, object given in %sarsort_variation1.php on line %d
-bool(false)
--- Iteration 21 --
-
-Warning: arsort() expects parameter 1 to be array, string given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, string given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, string given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, string given in %sarsort_variation1.php on line %d
-bool(false)
--- Iteration 22 --
-
-Warning: arsort() expects parameter 1 to be array, string given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, string given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, string given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, string given in %sarsort_variation1.php on line %d
-bool(false)
--- Iteration 23 --
-
-Warning: arsort() expects parameter 1 to be array, resource given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, resource given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, resource given in %sarsort_variation1.php on line %d
-bool(false)
-
-Warning: arsort() expects parameter 1 to be array, resource given in %sarsort_variation1.php on line %d
-bool(false)
-Done
diff --git a/ext/standard/tests/array/arsort_variation2.phpt b/ext/standard/tests/array/arsort_variation2.phpt
deleted file mode 100644
index e6674774ee..0000000000
--- a/ext/standard/tests/array/arsort_variation2.phpt
+++ /dev/null
@@ -1,308 +0,0 @@
---TEST--
-Test arsort() function : usage variations - unexpected values for 'sort_flags' argument
---FILE--
-<?php
-/* Prototype : proto bool arsort(array &array_arg [, int sort_flags])
- * Description: Sort an array and maintain index association
- Elements will be arranged from highest to lowest when this function has completed.
- * Source code: ext/standard/array.c
-*/
-
-/*
- * Testing arsort() by providing different unexpected values for flag argument
-*/
-
-echo "*** Testing arsort() : usage variations ***\n";
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// resource variable
-$fp = fopen(__FILE__, "r");
-
-// temperory array for checking unexpected behavior
-$unsorted_values = array(1 => 10, 2 => 2, 3 => 45);
-
-//array of values to iterate over
-$unexpected_values = array(
-
- // int data
-/*1*/ -2345,
-
- // float data
-/*2*/ 10.5,
- -10.5,
- 10.5e2,
- 10.6E-2,
- .5,
-
- // null data
-/*7*/ NULL,
- null,
-
- // boolean data
-/*9*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*13*/ "",
- '',
-
- // string data
-/*15*/ "string",
- 'string',
-
- // object data
-/*16*/ new stdclass(),
-
- // undefined data
-/*17*/ @undefined_var,
-
- // unset data
-/*18*/ @unset_var,
-
- // resource variable
-/*19*/ $fp
-
-);
-
-// loop though each element of the array and check the working of arsort()
-// when $flag argument is supplied with different values from $unexpected_values
-echo "\n-- Testing arsort() by supplying different unexpected values for 'sort_flags' argument --\n";
-
-$counter = 1;
-for($index = 0; $index < count($unexpected_values); $index ++) {
- echo "-- Iteration $counter --\n";
- $value = $unexpected_values [$index];
- $temp_array = $unsorted_values;
- var_dump( arsort($temp_array, $value) );
- var_dump($temp_array);
- $counter++;
-}
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing arsort() : usage variations ***
-
--- Testing arsort() by supplying different unexpected values for 'sort_flags' argument --
--- Iteration 1 --
-bool(true)
-array(3) {
- [3]=>
- int(45)
- [1]=>
- int(10)
- [2]=>
- int(2)
-}
--- Iteration 2 --
-bool(true)
-array(3) {
- [3]=>
- int(45)
- [2]=>
- int(2)
- [1]=>
- int(10)
-}
--- Iteration 3 --
-bool(true)
-array(3) {
- [3]=>
- int(45)
- [1]=>
- int(10)
- [2]=>
- int(2)
-}
--- Iteration 4 --
-bool(true)
-array(3) {
- [3]=>
- int(45)
- [1]=>
- int(10)
- [2]=>
- int(2)
-}
--- Iteration 5 --
-bool(true)
-array(3) {
- [3]=>
- int(45)
- [1]=>
- int(10)
- [2]=>
- int(2)
-}
--- Iteration 6 --
-bool(true)
-array(3) {
- [3]=>
- int(45)
- [1]=>
- int(10)
- [2]=>
- int(2)
-}
--- Iteration 7 --
-bool(true)
-array(3) {
- [3]=>
- int(45)
- [1]=>
- int(10)
- [2]=>
- int(2)
-}
--- Iteration 8 --
-bool(true)
-array(3) {
- [3]=>
- int(45)
- [1]=>
- int(10)
- [2]=>
- int(2)
-}
--- Iteration 9 --
-bool(true)
-array(3) {
- [3]=>
- int(45)
- [1]=>
- int(10)
- [2]=>
- int(2)
-}
--- Iteration 10 --
-bool(true)
-array(3) {
- [3]=>
- int(45)
- [1]=>
- int(10)
- [2]=>
- int(2)
-}
--- Iteration 11 --
-bool(true)
-array(3) {
- [3]=>
- int(45)
- [1]=>
- int(10)
- [2]=>
- int(2)
-}
--- Iteration 12 --
-bool(true)
-array(3) {
- [3]=>
- int(45)
- [1]=>
- int(10)
- [2]=>
- int(2)
-}
--- Iteration 13 --
-
-Warning: arsort() expects parameter 2 to be int, string given in %sarsort_variation2.php on line %d
-bool(false)
-array(3) {
- [1]=>
- int(10)
- [2]=>
- int(2)
- [3]=>
- int(45)
-}
--- Iteration 14 --
-
-Warning: arsort() expects parameter 2 to be int, string given in %sarsort_variation2.php on line %d
-bool(false)
-array(3) {
- [1]=>
- int(10)
- [2]=>
- int(2)
- [3]=>
- int(45)
-}
--- Iteration 15 --
-
-Warning: arsort() expects parameter 2 to be int, string given in %sarsort_variation2.php on line %d
-bool(false)
-array(3) {
- [1]=>
- int(10)
- [2]=>
- int(2)
- [3]=>
- int(45)
-}
--- Iteration 16 --
-
-Warning: arsort() expects parameter 2 to be int, string given in %sarsort_variation2.php on line %d
-bool(false)
-array(3) {
- [1]=>
- int(10)
- [2]=>
- int(2)
- [3]=>
- int(45)
-}
--- Iteration 17 --
-
-Warning: arsort() expects parameter 2 to be int, object given in %sarsort_variation2.php on line %d
-bool(false)
-array(3) {
- [1]=>
- int(10)
- [2]=>
- int(2)
- [3]=>
- int(45)
-}
--- Iteration 18 --
-
-Warning: arsort() expects parameter 2 to be int, string given in %sarsort_variation2.php on line %d
-bool(false)
-array(3) {
- [1]=>
- int(10)
- [2]=>
- int(2)
- [3]=>
- int(45)
-}
--- Iteration 19 --
-
-Warning: arsort() expects parameter 2 to be int, string given in %sarsort_variation2.php on line %d
-bool(false)
-array(3) {
- [1]=>
- int(10)
- [2]=>
- int(2)
- [3]=>
- int(45)
-}
--- Iteration 20 --
-
-Warning: arsort() expects parameter 2 to be int, resource given in %sarsort_variation2.php on line %d
-bool(false)
-array(3) {
- [1]=>
- int(10)
- [2]=>
- int(2)
- [3]=>
- int(45)
-}
-Done
diff --git a/ext/standard/tests/array/asort_variation1.phpt b/ext/standard/tests/array/asort_variation1.phpt
deleted file mode 100644
index 4594a3d171..0000000000
--- a/ext/standard/tests/array/asort_variation1.phpt
+++ /dev/null
@@ -1,399 +0,0 @@
---TEST--
-Test asort() function : usage variations - unexpected values for 'array_arg' argument
---FILE--
-<?php
-/* Prototype : bool asort(array &array_arg [, int sort_flags])
- * Description: Sort an array and maintain index association
- Elements will be arranged from lowest to highest when this function has completed.
- * Source code: ext/standard/array.c
-*/
-
-/*
- * testing asort() by providing different unexpected values for array argument with following flag values.
- * 1. flag value as defualt
- * 2. SORT_REGULAR - compare items normally
- * 3. SORT_NUMERIC - compare items numerically
- * 4. SORT_STRING - compare items as strings
-*/
-
-echo "*** Testing asort() : usage variations ***\n";
-
-// get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// resource variable
-$fp = fopen(__FILE__, "r");
-
-//array of values with indices to iterate over
-$unexpected_values = array (
-
- // int data
- 0 => 0,
- 1 => 1,
- 2 => 12345,
- 3 => -2345,
-
- // float data
- 4 => 10.5,
- 5 => -10.5,
- 6 => 10.5e3,
- 7 => 10.6E-2,
- 8 => .5,
-
- // null data
- 9 => NULL,
- 10 => null,
-
- // boolean data
- 11 => true,
- 12 => false,
- 13 => TRUE,
- 14 => FALSE,
-
- // empty data
- 15 => "",
- 16 => '',
-
- // string data
- 17 => "string",
- 18 => 'string',
-
- // object data
- 19 => new stdclass(),
-
- // undefined data
- 20 => @undefined_var,
-
- // unset data
- 21 => @unset_var,
-
- // resource variable
- 22 => $fp
-
-);
-
-// loop though each element of the array and check the working of asort()
-// when $array argument is supplied with different values from $unexpected_values
-echo "\n-- Testing asort() by supplying different unexpected values for 'array' argument --\n";
-echo "\n-- Flag values are defualt, SORT_REGULAR, SORT_NUMERIC, SORT_STRING --\n";
-
-$counter = 1;
-for($index = 0; $index < count($unexpected_values); $index ++) {
- echo "-- Iteration $counter --\n";
- $value = $unexpected_values [$index];
- var_dump( asort($value) ); // expecting : bool(false)
- var_dump( asort($value, SORT_REGULAR) ); // expecting : bool(false)
- var_dump( asort($value, SORT_NUMERIC) ); // expecting : bool(false)
- var_dump( asort($value, SORT_STRING) ); // expecting : bool(false)
- $counter++;
-}
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing asort() : usage variations ***
-
--- Testing asort() by supplying different unexpected values for 'array' argument --
-
--- Flag values are defualt, SORT_REGULAR, SORT_NUMERIC, SORT_STRING --
--- Iteration 1 --
-
-Warning: asort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
--- Iteration 2 --
-
-Warning: asort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
--- Iteration 3 --
-
-Warning: asort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
--- Iteration 4 --
-
-Warning: asort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
--- Iteration 5 --
-
-Warning: asort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
--- Iteration 6 --
-
-Warning: asort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
--- Iteration 7 --
-
-Warning: asort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
--- Iteration 8 --
-
-Warning: asort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
--- Iteration 9 --
-
-Warning: asort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
--- Iteration 10 --
-
-Warning: asort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
--- Iteration 11 --
-
-Warning: asort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
--- Iteration 12 --
-
-Warning: asort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
--- Iteration 13 --
-
-Warning: asort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
--- Iteration 14 --
-
-Warning: asort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
--- Iteration 15 --
-
-Warning: asort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
--- Iteration 16 --
-
-Warning: asort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
--- Iteration 17 --
-
-Warning: asort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
--- Iteration 18 --
-
-Warning: asort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
--- Iteration 19 --
-
-Warning: asort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
--- Iteration 20 --
-
-Warning: asort() expects parameter 1 to be array, object given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, object given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, object given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, object given in %s on line %d
-bool(false)
--- Iteration 21 --
-
-Warning: asort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
--- Iteration 22 --
-
-Warning: asort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
--- Iteration 23 --
-
-Warning: asort() expects parameter 1 to be array, resource given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, resource given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, resource given in %s on line %d
-bool(false)
-
-Warning: asort() expects parameter 1 to be array, resource given in %s on line %d
-bool(false)
-Done
diff --git a/ext/standard/tests/array/asort_variation2.phpt b/ext/standard/tests/array/asort_variation2.phpt
deleted file mode 100644
index e8dda190df..0000000000
--- a/ext/standard/tests/array/asort_variation2.phpt
+++ /dev/null
@@ -1,308 +0,0 @@
---TEST--
-Test asort() function : usage variations - unexpected values for 'sort_flags' argument
---FILE--
-<?php
-/* Prototype : proto bool asort(array &array_arg [, int sort_flags])
- * Description: Sort an array and maintain index association
- Elements will be arranged from lowest to highest when this function has completed.
- * Source code: ext/standard/array.c
-*/
-
-/*
- * Testing asort() by providing different unexpected values for flag argument
-*/
-
-echo "*** Testing asort() : usage variations ***\n";
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// resource variable
-$fp = fopen(__FILE__, "r");
-
-// temperory array for checking unexpected behavior
-$unsorted_values = array(1 => 10, 2 => 2, 3 => 45);
-
-//array of values to iterate over
-$unexpected_values = array(
-
- // int data
-/*1*/ -2345,
-
- // float data
-/*2*/ 10.5,
- -10.5,
- 10.5e2,
- 10.6E-2,
- .5,
-
- // null data
-/*7*/ NULL,
- null,
-
- // boolean data
-/*9*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*13*/ "",
- '',
-
- // string data
-/*15*/ "string",
- 'string',
-
- // object data
-/*16*/ new stdclass(),
-
- // undefined data
-/*17*/ @undefined_var,
-
- // unset data
-/*18*/ @unset_var,
-
- // resource variable
-/*19*/ $fp
-
-);
-
-// loop though each element of the array and check the working of asort()
-// when $flag argument is supplied with different values from $unexpected_values
-echo "\n-- Testing asort() by supplying different unexpected values for 'sort_flags' argument --\n";
-
-$counter = 1;
-for($index = 0; $index < count($unexpected_values); $index ++) {
- echo "-- Iteration $counter --\n";
- $value = $unexpected_values [$index];
- $temp_array = $unsorted_values;
- var_dump( asort($temp_array, $value) );
- var_dump($temp_array);
- $counter++;
-}
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing asort() : usage variations ***
-
--- Testing asort() by supplying different unexpected values for 'sort_flags' argument --
--- Iteration 1 --
-bool(true)
-array(3) {
- [2]=>
- int(2)
- [1]=>
- int(10)
- [3]=>
- int(45)
-}
--- Iteration 2 --
-bool(true)
-array(3) {
- [1]=>
- int(10)
- [2]=>
- int(2)
- [3]=>
- int(45)
-}
--- Iteration 3 --
-bool(true)
-array(3) {
- [2]=>
- int(2)
- [1]=>
- int(10)
- [3]=>
- int(45)
-}
--- Iteration 4 --
-bool(true)
-array(3) {
- [2]=>
- int(2)
- [1]=>
- int(10)
- [3]=>
- int(45)
-}
--- Iteration 5 --
-bool(true)
-array(3) {
- [2]=>
- int(2)
- [1]=>
- int(10)
- [3]=>
- int(45)
-}
--- Iteration 6 --
-bool(true)
-array(3) {
- [2]=>
- int(2)
- [1]=>
- int(10)
- [3]=>
- int(45)
-}
--- Iteration 7 --
-bool(true)
-array(3) {
- [2]=>
- int(2)
- [1]=>
- int(10)
- [3]=>
- int(45)
-}
--- Iteration 8 --
-bool(true)
-array(3) {
- [2]=>
- int(2)
- [1]=>
- int(10)
- [3]=>
- int(45)
-}
--- Iteration 9 --
-bool(true)
-array(3) {
- [2]=>
- int(2)
- [1]=>
- int(10)
- [3]=>
- int(45)
-}
--- Iteration 10 --
-bool(true)
-array(3) {
- [2]=>
- int(2)
- [1]=>
- int(10)
- [3]=>
- int(45)
-}
--- Iteration 11 --
-bool(true)
-array(3) {
- [2]=>
- int(2)
- [1]=>
- int(10)
- [3]=>
- int(45)
-}
--- Iteration 12 --
-bool(true)
-array(3) {
- [2]=>
- int(2)
- [1]=>
- int(10)
- [3]=>
- int(45)
-}
--- Iteration 13 --
-
-Warning: asort() expects parameter 2 to be int, string given in %s on line %d
-bool(false)
-array(3) {
- [1]=>
- int(10)
- [2]=>
- int(2)
- [3]=>
- int(45)
-}
--- Iteration 14 --
-
-Warning: asort() expects parameter 2 to be int, string given in %s on line %d
-bool(false)
-array(3) {
- [1]=>
- int(10)
- [2]=>
- int(2)
- [3]=>
- int(45)
-}
--- Iteration 15 --
-
-Warning: asort() expects parameter 2 to be int, string given in %s on line %d
-bool(false)
-array(3) {
- [1]=>
- int(10)
- [2]=>
- int(2)
- [3]=>
- int(45)
-}
--- Iteration 16 --
-
-Warning: asort() expects parameter 2 to be int, string given in %s on line %d
-bool(false)
-array(3) {
- [1]=>
- int(10)
- [2]=>
- int(2)
- [3]=>
- int(45)
-}
--- Iteration 17 --
-
-Warning: asort() expects parameter 2 to be int, object given in %s on line %d
-bool(false)
-array(3) {
- [1]=>
- int(10)
- [2]=>
- int(2)
- [3]=>
- int(45)
-}
--- Iteration 18 --
-
-Warning: asort() expects parameter 2 to be int, string given in %s on line %d
-bool(false)
-array(3) {
- [1]=>
- int(10)
- [2]=>
- int(2)
- [3]=>
- int(45)
-}
--- Iteration 19 --
-
-Warning: asort() expects parameter 2 to be int, string given in %s on line %d
-bool(false)
-array(3) {
- [1]=>
- int(10)
- [2]=>
- int(2)
- [3]=>
- int(45)
-}
--- Iteration 20 --
-
-Warning: asort() expects parameter 2 to be int, resource given in %s on line %d
-bool(false)
-array(3) {
- [1]=>
- int(10)
- [2]=>
- int(2)
- [3]=>
- int(45)
-}
-Done
diff --git a/ext/standard/tests/array/count_variation1.phpt b/ext/standard/tests/array/count_variation1.phpt
deleted file mode 100644
index 10406f71ff..0000000000
--- a/ext/standard/tests/array/count_variation1.phpt
+++ /dev/null
@@ -1,218 +0,0 @@
---TEST--
-Test count() function : usage variations - Pass different data types as $var arg
---FILE--
-<?php
-/* Prototype : int count(mixed $var [, int $mode])
- * Description: Count the number of elements in a variable (usually an array)
- * Source code: ext/standard/array.c
- */
-
-/*
- * aPass different data types as $var argument to count() to test behaviour
- */
-
-echo "*** Testing count() : usage variations ***\n";
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// get a class
-class classA
-{
- public function __toString() {
- return "Class A object";
- }
-}
-
-// heredoc string
-$heredoc = <<<EOT
-hello world
-EOT;
-
-// get a resource variable
-$fp = fopen(__FILE__, "r");
-
-// unexpected values to be passed to $var argument
-$inputs = array(
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 12.3456789000e10,
- 12.3456789000E-10,
- .5,
-
- // null data
-/*10*/ NULL,
- null,
-
- // boolean data
-/*12*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*16*/ "",
- '',
-
- // string data
-/*18*/ "string",
- 'string',
- $heredoc,
-
- // object data
-/*21*/ new classA(),
-
- // undefined data
-/*22*/ @$undefined_var,
-
- // unset data
-/*23*/ @$unset_var,
-
- // resource variable
-/*24*/ $fp
-);
-
-// loop through each element of $inputs to check the behavior of count()
-$iterator = 1;
-foreach($inputs as $input) {
- echo "\n-- Iteration $iterator --\n";
- var_dump( count($input) );
- $iterator++;
-};
-
-fclose($fp);
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing count() : usage variations ***
-
--- Iteration 1 --
-
-Warning: count(): Parameter must be an array or an object that implements Countable in %s on line %d
-int(1)
-
--- Iteration 2 --
-
-Warning: count(): Parameter must be an array or an object that implements Countable in %s on line %d
-int(1)
-
--- Iteration 3 --
-
-Warning: count(): Parameter must be an array or an object that implements Countable in %s on line %d
-int(1)
-
--- Iteration 4 --
-
-Warning: count(): Parameter must be an array or an object that implements Countable in %s on line %d
-int(1)
-
--- Iteration 5 --
-
-Warning: count(): Parameter must be an array or an object that implements Countable in %s on line %d
-int(1)
-
--- Iteration 6 --
-
-Warning: count(): Parameter must be an array or an object that implements Countable in %s on line %d
-int(1)
-
--- Iteration 7 --
-
-Warning: count(): Parameter must be an array or an object that implements Countable in %s on line %d
-int(1)
-
--- Iteration 8 --
-
-Warning: count(): Parameter must be an array or an object that implements Countable in %s on line %d
-int(1)
-
--- Iteration 9 --
-
-Warning: count(): Parameter must be an array or an object that implements Countable in %s on line %d
-int(1)
-
--- Iteration 10 --
-
-Warning: count(): Parameter must be an array or an object that implements Countable in %s on line %d
-int(0)
-
--- Iteration 11 --
-
-Warning: count(): Parameter must be an array or an object that implements Countable in %s on line %d
-int(0)
-
--- Iteration 12 --
-
-Warning: count(): Parameter must be an array or an object that implements Countable in %s on line %d
-int(1)
-
--- Iteration 13 --
-
-Warning: count(): Parameter must be an array or an object that implements Countable in %s on line %d
-int(1)
-
--- Iteration 14 --
-
-Warning: count(): Parameter must be an array or an object that implements Countable in %s on line %d
-int(1)
-
--- Iteration 15 --
-
-Warning: count(): Parameter must be an array or an object that implements Countable in %s on line %d
-int(1)
-
--- Iteration 16 --
-
-Warning: count(): Parameter must be an array or an object that implements Countable in %s on line %d
-int(1)
-
--- Iteration 17 --
-
-Warning: count(): Parameter must be an array or an object that implements Countable in %s on line %d
-int(1)
-
--- Iteration 18 --
-
-Warning: count(): Parameter must be an array or an object that implements Countable in %s on line %d
-int(1)
-
--- Iteration 19 --
-
-Warning: count(): Parameter must be an array or an object that implements Countable in %s on line %d
-int(1)
-
--- Iteration 20 --
-
-Warning: count(): Parameter must be an array or an object that implements Countable in %s on line %d
-int(1)
-
--- Iteration 21 --
-
-Warning: count(): Parameter must be an array or an object that implements Countable in %s on line %d
-int(1)
-
--- Iteration 22 --
-
-Warning: count(): Parameter must be an array or an object that implements Countable in %s on line %d
-int(0)
-
--- Iteration 23 --
-
-Warning: count(): Parameter must be an array or an object that implements Countable in %s on line %d
-int(0)
-
--- Iteration 24 --
-
-Warning: count(): Parameter must be an array or an object that implements Countable in %s on line %d
-int(1)
-Done
diff --git a/ext/standard/tests/array/count_variation2.phpt b/ext/standard/tests/array/count_variation2.phpt
deleted file mode 100644
index 0a654be183..0000000000
--- a/ext/standard/tests/array/count_variation2.phpt
+++ /dev/null
@@ -1,189 +0,0 @@
---TEST--
-Test count() function : usage variations - Pass different data types as $mode arg
---SKIPIF--
-<?php if (PHP_INT_SIZE != 8) die("skip this test is for 64-bit only");
---FILE--
-<?php
-/* Prototype : int count(mixed $var [, int $mode])
- * Description: Count the number of elements in a variable (usually an array)
- * Source code: ext/standard/array.c
- */
-
-/*
- * Pass different data types as $mode argument to count() to test behaviour
- */
-
-echo "*** Testing count() : usage variations ***\n";
-
-// Initialise function arguments not being substituted
-$var = array(1, 2, array ('one', 'two'));
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// get a class
-class classA
-{
- public function __toString() {
- return "Class A object";
- }
-}
-
-// heredoc string
-$heredoc = <<<EOT
-hello world
-EOT;
-
-// get a resource variable
-$fp = fopen(__FILE__, "r");
-
-// unexpected values to be passed to $mode argument
-$inputs = array(
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 12.3456789000e10,
- 12.3456789000E-10,
- .5,
-
- // null data
-/*10*/ NULL,
- null,
-
- // boolean data
-/*12*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*16*/ "",
- '',
-
- // string data
-/*18*/ "string",
- 'string',
- $heredoc,
-
- // object data
-/*21*/ new classA(),
-
- // undefined data
-/*22*/ @$undefined_var,
-
- // unset data
-/*23*/ @$unset_var,
-
- // resource variable
-/*24*/ $fp
-);
-
-// loop through each element of $inputs to check the behavior of count()
-$iterator = 1;
-foreach($inputs as $input) {
- echo "\n-- Iteration $iterator --\n";
- var_dump( count($var, $input) );
- $iterator++;
-};
-
-fclose($fp);
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing count() : usage variations ***
-
--- Iteration 1 --
-int(3)
-
--- Iteration 2 --
-int(5)
-
--- Iteration 3 --
-int(3)
-
--- Iteration 4 --
-int(3)
-
--- Iteration 5 --
-int(3)
-
--- Iteration 6 --
-int(3)
-
--- Iteration 7 --
-int(3)
-
--- Iteration 8 --
-int(3)
-
--- Iteration 9 --
-int(3)
-
--- Iteration 10 --
-int(3)
-
--- Iteration 11 --
-int(3)
-
--- Iteration 12 --
-int(5)
-
--- Iteration 13 --
-int(3)
-
--- Iteration 14 --
-int(5)
-
--- Iteration 15 --
-int(3)
-
--- Iteration 16 --
-
-Warning: count() expects parameter 2 to be int, string given in %s on line %d
-NULL
-
--- Iteration 17 --
-
-Warning: count() expects parameter 2 to be int, string given in %s on line %d
-NULL
-
--- Iteration 18 --
-
-Warning: count() expects parameter 2 to be int, string given in %s on line %d
-NULL
-
--- Iteration 19 --
-
-Warning: count() expects parameter 2 to be int, string given in %s on line %d
-NULL
-
--- Iteration 20 --
-
-Warning: count() expects parameter 2 to be int, string given in %s on line %d
-NULL
-
--- Iteration 21 --
-
-Warning: count() expects parameter 2 to be int, object given in %s on line %d
-NULL
-
--- Iteration 22 --
-int(3)
-
--- Iteration 23 --
-int(3)
-
--- Iteration 24 --
-
-Warning: count() expects parameter 2 to be int, resource given in %s on line %d
-NULL
-Done
diff --git a/ext/standard/tests/array/current_variation1.phpt b/ext/standard/tests/array/current_variation1.phpt
deleted file mode 100644
index c6c66f43c9..0000000000
--- a/ext/standard/tests/array/current_variation1.phpt
+++ /dev/null
@@ -1,217 +0,0 @@
---TEST--
-Test current() function : usage variations - Pass different data types as $array_arg arg
---FILE--
-<?php
-/* Prototype : mixed current(array $array_arg)
- * Description: Return the element currently pointed to by the internal array pointer
- * Source code: ext/standard/array.c
- * Alias to functions: pos
- */
-
-/*
- * Pass different data types as $array_arg argument to current() to test behaviour
- */
-
-echo "*** Testing current() : usage variations ***\n";
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// get a class
-class classA
-{
- var $var1;
- public function __toString() {
- return "Class A object";
- }
-}
-
-// heredoc string
-$heredoc = <<<EOT
-hello world
-EOT;
-
-// get a resource variable
-$fp = fopen(__FILE__, "r");
-
-// unexpected values to be passed to $array_arg argument
-$inputs = array(
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 12.3456789000e10,
- 12.3456789000E-10,
- .5,
-
- // null data
-/*10*/ NULL,
- null,
-
- // boolean data
-/*12*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*16*/ "",
- '',
-
- // string data
-/*18*/ "string",
- 'string',
- $heredoc,
-
- // object data
-/*21*/ new classA(),
-
- // undefined data
-/*22*/ @$undefined_var,
-
- // unset data
-/*23*/ @$unset_var,
-
- // resource variable
-/*24*/ $fp
-);
-
-// loop through each element of $inputs to check the behavior of current()
-$iterator = 1;
-foreach($inputs as $input) {
- echo "\n-- Iteration $iterator --\n";
- var_dump( current($input) );
- $iterator++;
-};
-
-fclose($fp);
-?>
-===DONE===
---EXPECTF--
-*** Testing current() : usage variations ***
-
--- Iteration 1 --
-
-Warning: current() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 2 --
-
-Warning: current() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 3 --
-
-Warning: current() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 4 --
-
-Warning: current() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 5 --
-
-Warning: current() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 6 --
-
-Warning: current() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 7 --
-
-Warning: current() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 8 --
-
-Warning: current() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 9 --
-
-Warning: current() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 10 --
-
-Warning: current() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 11 --
-
-Warning: current() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 12 --
-
-Warning: current() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 13 --
-
-Warning: current() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 14 --
-
-Warning: current() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 15 --
-
-Warning: current() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 16 --
-
-Warning: current() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 17 --
-
-Warning: current() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 18 --
-
-Warning: current() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 19 --
-
-Warning: current() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 20 --
-
-Warning: current() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 21 --
-NULL
-
--- Iteration 22 --
-
-Warning: current() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 23 --
-
-Warning: current() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 24 --
-
-Warning: current() expects parameter 1 to be array, resource given in %s on line %d
-NULL
-===DONE===
diff --git a/ext/standard/tests/array/end_variation1.phpt b/ext/standard/tests/array/end_variation1.phpt
deleted file mode 100644
index 2b7f4cd9d4..0000000000
--- a/ext/standard/tests/array/end_variation1.phpt
+++ /dev/null
@@ -1,220 +0,0 @@
---TEST--
-Test end() function : usage variations - Pass different data types as $array_arg
---FILE--
-<?php
-/* Prototype : mixed end(array $array_arg)
- * Description: Advances array argument's internal pointer to the last element and return it
- * Source code: ext/standard/array.c
- */
-
-/*
- * Pass different data types as $array_arg to test behaviour of end()
- */
-
-echo "*** Testing end() : usage variations ***\n";
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// get a class
-class classA
-{
- var $foo = 'hello, world';
- public function __toString() {
- return "Class A object";
- }
-}
-
-// heredoc string
-$heredoc = <<<EOT
-hello world
-EOT;
-
-// get a resource variable
-$fp = fopen(__FILE__, "r");
-
-// unexpected values to be passed to $array_arg argument
-$inputs = array(
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 12.3456789000e10,
- 12.3456789000E-10,
- .5,
-
- // null data
-/*10*/ NULL,
- null,
-
- // boolean data
-/*12*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*16*/ "",
- '',
- array(),
-
- // string data
-/*19*/ "string",
- 'string',
- $heredoc,
-
- // object data
-/*22*/ new classA(),
-
- // undefined data
-/*23*/ @$undefined_var,
-
- // unset data
-/*24*/ @$unset_var,
-
- // resource variable
-/*25*/ $fp
-);
-
-// loop through each element of $inputs to check the behavior of end()
-$iterator = 1;
-foreach($inputs as $input) {
- echo "\n-- Iteration $iterator --\n";
- var_dump( end($input) );
- $iterator++;
-};
-
-fclose($fp);
-?>
-===DONE===
---EXPECTF--
-*** Testing end() : usage variations ***
-
--- Iteration 1 --
-
-Warning: end() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 2 --
-
-Warning: end() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 3 --
-
-Warning: end() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 4 --
-
-Warning: end() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 5 --
-
-Warning: end() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 6 --
-
-Warning: end() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 7 --
-
-Warning: end() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 8 --
-
-Warning: end() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 9 --
-
-Warning: end() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 10 --
-
-Warning: end() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 11 --
-
-Warning: end() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 12 --
-
-Warning: end() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 13 --
-
-Warning: end() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 14 --
-
-Warning: end() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 15 --
-
-Warning: end() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 16 --
-
-Warning: end() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 17 --
-
-Warning: end() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 18 --
-bool(false)
-
--- Iteration 19 --
-
-Warning: end() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 20 --
-
-Warning: end() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 21 --
-
-Warning: end() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 22 --
-string(12) "hello, world"
-
--- Iteration 23 --
-
-Warning: end() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 24 --
-
-Warning: end() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 25 --
-
-Warning: end() expects parameter 1 to be array, resource given in %s on line %d
-NULL
-===DONE===
diff --git a/ext/standard/tests/array/key_variation1.phpt b/ext/standard/tests/array/key_variation1.phpt
deleted file mode 100644
index 12a97e1421..0000000000
--- a/ext/standard/tests/array/key_variation1.phpt
+++ /dev/null
@@ -1,220 +0,0 @@
---TEST--
-Test key() function : usage variations - Pass different data types as $array_arg arg.
---FILE--
-<?php
-/* Prototype : mixed key(array $array_arg)
- * Description: Return the key of the element currently pointed to by the internal array pointer
- * Source code: ext/standard/array.c
- */
-
-/*
- * Pass different data types as $array_arg argument to test behaviour of key()
- */
-
-echo "*** Testing key() : usage variations ***\n";
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// get a class
-class classA
-{
- var $var1;
- public function __toString() {
- return "Class A object";
- }
-}
-
-// heredoc string
-$heredoc = <<<EOT
-hello world
-EOT;
-
-// get a resource variable
-$fp = fopen(__FILE__, "r");
-
-// unexpected values to be passed to $array_arg argument
-$inputs = array(
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 12.3456789000e10,
- 12.3456789000E-10,
- .5,
-
- // null data
-/*10*/ NULL,
- null,
-
- // boolean data
-/*12*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*16*/ "",
- '',
- array(),
-
- // string data
-/*19*/ "string",
- 'string',
- $heredoc,
-
- // object data
-/*22*/ new classA(),
-
- // undefined data
-/*23*/ @$undefined_var,
-
- // unset data
-/*24*/ @$unset_var,
-
- // resource variable
-/*25*/ $fp
-);
-
-// loop through each element of $inputs to check the behavior of key()
-$iterator = 1;
-foreach($inputs as $input) {
- echo "\n-- Iteration $iterator --\n";
- var_dump( key($input) );
- $iterator++;
-};
-
-fclose($fp);
-?>
-===DONE===
---EXPECTF--
-*** Testing key() : usage variations ***
-
--- Iteration 1 --
-
-Warning: key() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 2 --
-
-Warning: key() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 3 --
-
-Warning: key() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 4 --
-
-Warning: key() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 5 --
-
-Warning: key() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 6 --
-
-Warning: key() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 7 --
-
-Warning: key() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 8 --
-
-Warning: key() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 9 --
-
-Warning: key() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 10 --
-
-Warning: key() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 11 --
-
-Warning: key() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 12 --
-
-Warning: key() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 13 --
-
-Warning: key() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 14 --
-
-Warning: key() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 15 --
-
-Warning: key() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 16 --
-
-Warning: key() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 17 --
-
-Warning: key() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 18 --
-NULL
-
--- Iteration 19 --
-
-Warning: key() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 20 --
-
-Warning: key() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 21 --
-
-Warning: key() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 22 --
-string(4) "var1"
-
--- Iteration 23 --
-
-Warning: key() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 24 --
-
-Warning: key() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 25 --
-
-Warning: key() expects parameter 1 to be array, resource given in %s on line %d
-NULL
-===DONE===
diff --git a/ext/standard/tests/array/krsort_variation1.phpt b/ext/standard/tests/array/krsort_variation1.phpt
deleted file mode 100644
index 8b44de314e..0000000000
--- a/ext/standard/tests/array/krsort_variation1.phpt
+++ /dev/null
@@ -1,397 +0,0 @@
---TEST--
-Test krsort() function : usage variations - unexpected values for 'array' argument
---FILE--
-<?php
-/* Prototype : bool krsort(array &array_arg [, int sort_flags])
- * Description: Sort an array by key in reverse order, maintaining key to data correlation
- * Source code: ext/standard/array.c
-*/
-
-/*
- * testing krsort() by providing different unexpected values for array argument
- * with following flag values:
- * 1.flag value as defualt
- * 2.SORT_REGULAR - compare items normally
- * 3.SORT_NUMERIC - compare items numerically
- * 4.SORT_STRING - compare items as strings
-*/
-
-echo "*** Testing krsort() : usage variations ***\n";
-
-// get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// resource variable
-$fp = fopen(__FILE__, "r");
-
-$unexpected_values = array (
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 10.5e3,
- 10.6E-2,
- 0.5,
-
- // null data
-/*10*/ NULL,
- null,
-
- // boolean data
-/*11*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*15*/ "",
- '',
-
- // string data
-/*17*/ "string",
- 'string',
-
- // object data
-/*19*/ new stdclass(),
-
- // undefined data
-/*20*/ @undefined_var,
-
- // unset data
-/*21*/ @unset_var,
-
- // resource variable
-/*22*/ $fp
-);
-
-// loop though each element of the array and check the working of krsort()
-// when $array argument is supplied with different values from $unexpected_values
-echo "\n-- Testing krsort() by supplying different unexpected values for 'array' argument --\n";
-echo "\n-- Flag values are defualt, SORT_REGULAR, SORT_NUMERIC, SORT_STRING --\n";
-
-$counter = 1;
-for($index = 0; $index < count($unexpected_values); $index ++) {
- echo "-- Iteration $counter --\n";
- $value = $unexpected_values [$index];
- var_dump( krsort($value) ); // expecting : bool(false)
- var_dump( krsort($value, SORT_REGULAR) ); // expecting : bool(false)
- var_dump( krsort($value, SORT_NUMERIC) ); // expecting : bool(false)
- var_dump( krsort($value, SORT_STRING) ); // expecting : bool(false)
- $counter++;
-}
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing krsort() : usage variations ***
-
--- Testing krsort() by supplying different unexpected values for 'array' argument --
-
--- Flag values are defualt, SORT_REGULAR, SORT_NUMERIC, SORT_STRING --
--- Iteration 1 --
-
-Warning: krsort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
--- Iteration 2 --
-
-Warning: krsort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
--- Iteration 3 --
-
-Warning: krsort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
--- Iteration 4 --
-
-Warning: krsort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
--- Iteration 5 --
-
-Warning: krsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
--- Iteration 6 --
-
-Warning: krsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
--- Iteration 7 --
-
-Warning: krsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
--- Iteration 8 --
-
-Warning: krsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
--- Iteration 9 --
-
-Warning: krsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
--- Iteration 10 --
-
-Warning: krsort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
--- Iteration 11 --
-
-Warning: krsort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
--- Iteration 12 --
-
-Warning: krsort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
--- Iteration 13 --
-
-Warning: krsort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
--- Iteration 14 --
-
-Warning: krsort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
--- Iteration 15 --
-
-Warning: krsort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
--- Iteration 16 --
-
-Warning: krsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
--- Iteration 17 --
-
-Warning: krsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
--- Iteration 18 --
-
-Warning: krsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
--- Iteration 19 --
-
-Warning: krsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
--- Iteration 20 --
-
-Warning: krsort() expects parameter 1 to be array, object given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, object given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, object given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, object given in %s on line %d
-bool(false)
--- Iteration 21 --
-
-Warning: krsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
--- Iteration 22 --
-
-Warning: krsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
--- Iteration 23 --
-
-Warning: krsort() expects parameter 1 to be array, resource given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, resource given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, resource given in %s on line %d
-bool(false)
-
-Warning: krsort() expects parameter 1 to be array, resource given in %s on line %d
-bool(false)
-Done
diff --git a/ext/standard/tests/array/krsort_variation2.phpt b/ext/standard/tests/array/krsort_variation2.phpt
deleted file mode 100644
index 95080b5507..0000000000
--- a/ext/standard/tests/array/krsort_variation2.phpt
+++ /dev/null
@@ -1,307 +0,0 @@
---TEST--
-Test krsort() function : usage variations - unexpected values for 'sort_flags' argument
---FILE--
-<?php
-/* Prototype : bool krsort(array &array_arg [, int sort_flags])
- * Description: Sort an array by key in reverse order, maintaining key to data correlation
- * Source code: ext/standard/array.c
-*/
-
-/*
- * Testing krsort() by providing different unexpected values for flag argument
-*/
-
-echo "*** Testing krsort() : usage variations ***\n";
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// resource variable
-$fp = fopen(__FILE__, "r");
-
-// an array for checking unexpected behavior
-$unsorted_values = array(10 => 10, 2 => 2, 45 => 45);
-
-//array of unexpected values to iterate over
-$unexpected_values = array (
-
- // int data
-/*1*/ -2345,
-
- // float data
-/*2*/ 10.5,
- -10.5,
- 10.5e2,
- 10.6E-2,
- .5,
-
- // null data
-/*7*/ NULL,
- null,
-
- // boolean data
-/*9*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*13*/ "",
- '',
-
- // string data
-/*15*/ "string",
- 'string',
-
- // object data
-/*16*/ new stdclass(),
-
- // undefined data
-/*17*/ @undefined_var,
-
- // unset data
-/*18*/ @unset_var,
-
- // resource variable
-/*19*/ $fp
-
-);
-
-// loop though each element of the array and check the working of krsort()
-// when 'sort_flags' argument is supplied with different values
-echo "\n-- Testing krsort() by supplying different unexpected values for 'sort_flags' argument --\n";
-
-$counter = 1;
-for($index = 0; $index < count($unexpected_values); $index ++) {
- echo "-- Iteration $counter --\n";
- $value = $unexpected_values [$index];
- $temp_array = $unsorted_values;
- var_dump( krsort($temp_array, $value) );
- var_dump($temp_array);
- $counter++;
-}
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing krsort() : usage variations ***
-
--- Testing krsort() by supplying different unexpected values for 'sort_flags' argument --
--- Iteration 1 --
-bool(true)
-array(3) {
- [45]=>
- int(45)
- [10]=>
- int(10)
- [2]=>
- int(2)
-}
--- Iteration 2 --
-bool(true)
-array(3) {
- [45]=>
- int(45)
- [2]=>
- int(2)
- [10]=>
- int(10)
-}
--- Iteration 3 --
-bool(true)
-array(3) {
- [45]=>
- int(45)
- [10]=>
- int(10)
- [2]=>
- int(2)
-}
--- Iteration 4 --
-bool(true)
-array(3) {
- [45]=>
- int(45)
- [10]=>
- int(10)
- [2]=>
- int(2)
-}
--- Iteration 5 --
-bool(true)
-array(3) {
- [45]=>
- int(45)
- [10]=>
- int(10)
- [2]=>
- int(2)
-}
--- Iteration 6 --
-bool(true)
-array(3) {
- [45]=>
- int(45)
- [10]=>
- int(10)
- [2]=>
- int(2)
-}
--- Iteration 7 --
-bool(true)
-array(3) {
- [45]=>
- int(45)
- [10]=>
- int(10)
- [2]=>
- int(2)
-}
--- Iteration 8 --
-bool(true)
-array(3) {
- [45]=>
- int(45)
- [10]=>
- int(10)
- [2]=>
- int(2)
-}
--- Iteration 9 --
-bool(true)
-array(3) {
- [45]=>
- int(45)
- [10]=>
- int(10)
- [2]=>
- int(2)
-}
--- Iteration 10 --
-bool(true)
-array(3) {
- [45]=>
- int(45)
- [10]=>
- int(10)
- [2]=>
- int(2)
-}
--- Iteration 11 --
-bool(true)
-array(3) {
- [45]=>
- int(45)
- [10]=>
- int(10)
- [2]=>
- int(2)
-}
--- Iteration 12 --
-bool(true)
-array(3) {
- [45]=>
- int(45)
- [10]=>
- int(10)
- [2]=>
- int(2)
-}
--- Iteration 13 --
-
-Warning: krsort() expects parameter 2 to be int, string given in %s on line %d
-bool(false)
-array(3) {
- [10]=>
- int(10)
- [2]=>
- int(2)
- [45]=>
- int(45)
-}
--- Iteration 14 --
-
-Warning: krsort() expects parameter 2 to be int, string given in %s on line %d
-bool(false)
-array(3) {
- [10]=>
- int(10)
- [2]=>
- int(2)
- [45]=>
- int(45)
-}
--- Iteration 15 --
-
-Warning: krsort() expects parameter 2 to be int, string given in %s on line %d
-bool(false)
-array(3) {
- [10]=>
- int(10)
- [2]=>
- int(2)
- [45]=>
- int(45)
-}
--- Iteration 16 --
-
-Warning: krsort() expects parameter 2 to be int, string given in %s on line %d
-bool(false)
-array(3) {
- [10]=>
- int(10)
- [2]=>
- int(2)
- [45]=>
- int(45)
-}
--- Iteration 17 --
-
-Warning: krsort() expects parameter 2 to be int, object given in %s on line %d
-bool(false)
-array(3) {
- [10]=>
- int(10)
- [2]=>
- int(2)
- [45]=>
- int(45)
-}
--- Iteration 18 --
-
-Warning: krsort() expects parameter 2 to be int, string given in %s on line %d
-bool(false)
-array(3) {
- [10]=>
- int(10)
- [2]=>
- int(2)
- [45]=>
- int(45)
-}
--- Iteration 19 --
-
-Warning: krsort() expects parameter 2 to be int, string given in %s on line %d
-bool(false)
-array(3) {
- [10]=>
- int(10)
- [2]=>
- int(2)
- [45]=>
- int(45)
-}
--- Iteration 20 --
-
-Warning: krsort() expects parameter 2 to be int, resource given in %s on line %d
-bool(false)
-array(3) {
- [10]=>
- int(10)
- [2]=>
- int(2)
- [45]=>
- int(45)
-}
-Done
diff --git a/ext/standard/tests/array/ksort_variation1.phpt b/ext/standard/tests/array/ksort_variation1.phpt
deleted file mode 100644
index 185fac760c..0000000000
--- a/ext/standard/tests/array/ksort_variation1.phpt
+++ /dev/null
@@ -1,397 +0,0 @@
---TEST--
-Test ksort() function : usage variations - unexpected values for 'array' argument
---FILE--
-<?php
-/* Prototype : bool ksort(array &array [, int sort_flags])
- * Description: Sort an array by key, maintaining key to data correlation
- * Source code: ext/standard/array.c
-*/
-
-/*
- * testing ksort() by providing different unexpected values for array argument with following flag values:
- * 1. flag value as defualt
- * 2. SORT_REGULAR - compare items normally
- * 3. SORT_NUMERIC - compare items numerically
- * 4. SORT_STRING - compare items as strings
-*/
-
-echo "*** Testing ksort() : usage variations ***\n";
-
-// get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// resource variable
-$fp = fopen(__FILE__, "r");
-
-$unexpected_values = array (
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 10.5e3,
- 10.6E-2,
- 0.5,
-
- // null data
-/*10*/ NULL,
- null,
-
- // boolean data
-/*11*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*15*/ "",
- '',
-
- // string data
-/*17*/ "string",
- 'string',
-
- // object data
-/*19*/ new stdclass(),
-
- // undefined data
-/*20*/ @undefined_var,
-
- // unset data
-/*21*/ @unset_var,
-
- // resource variable
-/*22*/ $fp
-
-);
-
-// loop though each element of the array and check the working of ksort()
-// when $array argument is supplied with different values from $unexpected_values
-echo "\n-- Testing ksort() by supplying different unexpected values for 'array' argument --\n";
-echo "\n-- Flag values are defualt, SORT_REGULAR, SORT_NUMERIC, SORT_STRING --\n";
-
-$counter = 1;
-for($index = 0; $index < count($unexpected_values); $index ++) {
- echo "-- Iteration $counter --\n";
- $value = $unexpected_values [$index];
- var_dump( ksort($value) ); // expecting : bool(false)
- var_dump( ksort($value, SORT_REGULAR) ); // expecting : bool(false)
- var_dump( ksort($value, SORT_NUMERIC) ); // expecting : bool(false)
- var_dump( ksort($value, SORT_STRING) ); // expecting : bool(false)
- $counter++;
-}
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing ksort() : usage variations ***
-
--- Testing ksort() by supplying different unexpected values for 'array' argument --
-
--- Flag values are defualt, SORT_REGULAR, SORT_NUMERIC, SORT_STRING --
--- Iteration 1 --
-
-Warning: ksort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
--- Iteration 2 --
-
-Warning: ksort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
--- Iteration 3 --
-
-Warning: ksort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
--- Iteration 4 --
-
-Warning: ksort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
--- Iteration 5 --
-
-Warning: ksort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
--- Iteration 6 --
-
-Warning: ksort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
--- Iteration 7 --
-
-Warning: ksort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
--- Iteration 8 --
-
-Warning: ksort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
--- Iteration 9 --
-
-Warning: ksort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
--- Iteration 10 --
-
-Warning: ksort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
--- Iteration 11 --
-
-Warning: ksort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
--- Iteration 12 --
-
-Warning: ksort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
--- Iteration 13 --
-
-Warning: ksort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
--- Iteration 14 --
-
-Warning: ksort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
--- Iteration 15 --
-
-Warning: ksort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
--- Iteration 16 --
-
-Warning: ksort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
--- Iteration 17 --
-
-Warning: ksort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
--- Iteration 18 --
-
-Warning: ksort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
--- Iteration 19 --
-
-Warning: ksort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
--- Iteration 20 --
-
-Warning: ksort() expects parameter 1 to be array, object given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, object given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, object given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, object given in %s on line %d
-bool(false)
--- Iteration 21 --
-
-Warning: ksort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
--- Iteration 22 --
-
-Warning: ksort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
--- Iteration 23 --
-
-Warning: ksort() expects parameter 1 to be array, resource given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, resource given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, resource given in %s on line %d
-bool(false)
-
-Warning: ksort() expects parameter 1 to be array, resource given in %s on line %d
-bool(false)
-Done
diff --git a/ext/standard/tests/array/ksort_variation2.phpt b/ext/standard/tests/array/ksort_variation2.phpt
deleted file mode 100644
index c80541ea27..0000000000
--- a/ext/standard/tests/array/ksort_variation2.phpt
+++ /dev/null
@@ -1,307 +0,0 @@
---TEST--
-Test ksort() function : usage variations - unexpected values for 'sort_flags' argument
---FILE--
-<?php
-/* Prototype : bool ksort(array &array_arg [, int sort_flags])
- * Description: Sort an array by key, maintaining key to data correlation
- * Source code: ext/standard/array.c
-*/
-
-/*
- * Testing ksort() by providing different unexpected values for flag argument
-*/
-
-echo "*** Testing ksort() : usage variations ***\n";
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// resource variable
-$fp = fopen(__FILE__, "r");
-
-// an array for checking unexpected behavior
-$unsorted_values = array(10 => 10, 2 => 2, 45 => 45);
-
-//array of unexpected values to iterate over
-$unexpected_values = array (
-
- // int data
-/*1*/ -2345,
-
- // float data
-/*2*/ 10.5,
- -10.5,
- 10.5e2,
- 10.6E-2,
- .5,
-
- // null data
-/*7*/ NULL,
- null,
-
- // boolean data
-/*9*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*13*/ "",
- '',
-
- // string data
-/*15*/ "string",
- 'string',
-
- // object data
-/*16*/ new stdclass(),
-
- // undefined data
-/*17*/ @undefined_var,
-
- // unset data
-/*18*/ @unset_var,
-
- // resource variable
-/*19*/ $fp
-
-);
-
-// loop though each element of the array and check the working of ksort()
-// when 'sort_flags' argument is supplied with different values
-echo "\n-- Testing ksort() by supplying different unexpected values for 'sort_flags' argument --\n";
-
-$counter = 1;
-for($index = 0; $index < count($unexpected_values); $index ++) {
- echo "-- Iteration $counter --\n";
- $value = $unexpected_values [$index];
- $temp_array = $unsorted_values;
- var_dump( ksort($temp_array, $value) );
- var_dump($temp_array);
- $counter++;
-}
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing ksort() : usage variations ***
-
--- Testing ksort() by supplying different unexpected values for 'sort_flags' argument --
--- Iteration 1 --
-bool(true)
-array(3) {
- [2]=>
- int(2)
- [10]=>
- int(10)
- [45]=>
- int(45)
-}
--- Iteration 2 --
-bool(true)
-array(3) {
- [10]=>
- int(10)
- [2]=>
- int(2)
- [45]=>
- int(45)
-}
--- Iteration 3 --
-bool(true)
-array(3) {
- [2]=>
- int(2)
- [10]=>
- int(10)
- [45]=>
- int(45)
-}
--- Iteration 4 --
-bool(true)
-array(3) {
- [2]=>
- int(2)
- [10]=>
- int(10)
- [45]=>
- int(45)
-}
--- Iteration 5 --
-bool(true)
-array(3) {
- [2]=>
- int(2)
- [10]=>
- int(10)
- [45]=>
- int(45)
-}
--- Iteration 6 --
-bool(true)
-array(3) {
- [2]=>
- int(2)
- [10]=>
- int(10)
- [45]=>
- int(45)
-}
--- Iteration 7 --
-bool(true)
-array(3) {
- [2]=>
- int(2)
- [10]=>
- int(10)
- [45]=>
- int(45)
-}
--- Iteration 8 --
-bool(true)
-array(3) {
- [2]=>
- int(2)
- [10]=>
- int(10)
- [45]=>
- int(45)
-}
--- Iteration 9 --
-bool(true)
-array(3) {
- [2]=>
- int(2)
- [10]=>
- int(10)
- [45]=>
- int(45)
-}
--- Iteration 10 --
-bool(true)
-array(3) {
- [2]=>
- int(2)
- [10]=>
- int(10)
- [45]=>
- int(45)
-}
--- Iteration 11 --
-bool(true)
-array(3) {
- [2]=>
- int(2)
- [10]=>
- int(10)
- [45]=>
- int(45)
-}
--- Iteration 12 --
-bool(true)
-array(3) {
- [2]=>
- int(2)
- [10]=>
- int(10)
- [45]=>
- int(45)
-}
--- Iteration 13 --
-
-Warning: ksort() expects parameter 2 to be int, string given in %s on line %d
-bool(false)
-array(3) {
- [10]=>
- int(10)
- [2]=>
- int(2)
- [45]=>
- int(45)
-}
--- Iteration 14 --
-
-Warning: ksort() expects parameter 2 to be int, string given in %s on line %d
-bool(false)
-array(3) {
- [10]=>
- int(10)
- [2]=>
- int(2)
- [45]=>
- int(45)
-}
--- Iteration 15 --
-
-Warning: ksort() expects parameter 2 to be int, string given in %s on line %d
-bool(false)
-array(3) {
- [10]=>
- int(10)
- [2]=>
- int(2)
- [45]=>
- int(45)
-}
--- Iteration 16 --
-
-Warning: ksort() expects parameter 2 to be int, string given in %s on line %d
-bool(false)
-array(3) {
- [10]=>
- int(10)
- [2]=>
- int(2)
- [45]=>
- int(45)
-}
--- Iteration 17 --
-
-Warning: ksort() expects parameter 2 to be int, object given in %s on line %d
-bool(false)
-array(3) {
- [10]=>
- int(10)
- [2]=>
- int(2)
- [45]=>
- int(45)
-}
--- Iteration 18 --
-
-Warning: ksort() expects parameter 2 to be int, string given in %s on line %d
-bool(false)
-array(3) {
- [10]=>
- int(10)
- [2]=>
- int(2)
- [45]=>
- int(45)
-}
--- Iteration 19 --
-
-Warning: ksort() expects parameter 2 to be int, string given in %s on line %d
-bool(false)
-array(3) {
- [10]=>
- int(10)
- [2]=>
- int(2)
- [45]=>
- int(45)
-}
--- Iteration 20 --
-
-Warning: ksort() expects parameter 2 to be int, resource given in %s on line %d
-bool(false)
-array(3) {
- [10]=>
- int(10)
- [2]=>
- int(2)
- [45]=>
- int(45)
-}
-Done
diff --git a/ext/standard/tests/array/natcasesort_variation1.phpt b/ext/standard/tests/array/natcasesort_variation1.phpt
deleted file mode 100644
index 98d6297a3f..0000000000
--- a/ext/standard/tests/array/natcasesort_variation1.phpt
+++ /dev/null
@@ -1,222 +0,0 @@
---TEST--
-Test natcasesort() function : usage variations - Pass different data types as $array_arg arg
---FILE--
-<?php
-/* Prototype : bool natcasesort(array &$array_arg)
- * Description: Sort an array using case-insensitive natural sort
- * Source code: ext/standard/array.c
- */
-
-/*
- * Pass different data types as $array_arg argument to natcasesort() to test behaviour
- */
-
-echo "*** Testing natcasesort() : usage variation ***\n";
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// get a class
-class classA
-{
- public function __toString() {
- return "Class A object";
- }
-}
-
-// heredoc string
-$heredoc = <<<EOT
-hello world
-EOT;
-
-// get a resource variable
-$fp = fopen(__FILE__, "r");
-
-// unexpected values to be passed to $array_arg argument
-$inputs = array(
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 12.3456789000e10,
- 12.3456789000E-10,
- .5,
-
- // null data
-/*10*/ NULL,
- null,
-
- // boolean data
-/*12*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*16*/ "",
- '',
- array(),
-
- // string data
-/*19*/ "string",
- 'string',
- $heredoc,
-
- // object data
-/*22*/ new classA(),
-
- // undefined data
-/*23*/ @$undefined_var,
-
- // unset data
-/*24*/ @$unset_var,
-
- // resource variable
-/*25*/ $fp
-);
-
-// loop through each element of $inputs to check the behavior of natcasesort()
-$iterator = 1;
-foreach($inputs as $input) {
- echo "\n-- Iteration $iterator --\n";
- var_dump( natcasesort($input) );
- $iterator++;
-};
-
-fclose($fp);
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing natcasesort() : usage variation ***
-
--- Iteration 1 --
-
-Warning: natcasesort() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 2 --
-
-Warning: natcasesort() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 3 --
-
-Warning: natcasesort() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 4 --
-
-Warning: natcasesort() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 5 --
-
-Warning: natcasesort() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 6 --
-
-Warning: natcasesort() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 7 --
-
-Warning: natcasesort() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 8 --
-
-Warning: natcasesort() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 9 --
-
-Warning: natcasesort() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 10 --
-
-Warning: natcasesort() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 11 --
-
-Warning: natcasesort() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 12 --
-
-Warning: natcasesort() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 13 --
-
-Warning: natcasesort() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 14 --
-
-Warning: natcasesort() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 15 --
-
-Warning: natcasesort() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 16 --
-
-Warning: natcasesort() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 17 --
-
-Warning: natcasesort() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 18 --
-bool(true)
-
--- Iteration 19 --
-
-Warning: natcasesort() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 20 --
-
-Warning: natcasesort() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 21 --
-
-Warning: natcasesort() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 22 --
-
-Warning: natcasesort() expects parameter 1 to be array, object given in %s on line %d
-NULL
-
--- Iteration 23 --
-
-Warning: natcasesort() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 24 --
-
-Warning: natcasesort() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 25 --
-
-Warning: natcasesort() expects parameter 1 to be array, resource given in %s on line %d
-NULL
-Done
diff --git a/ext/standard/tests/array/next_variation1.phpt b/ext/standard/tests/array/next_variation1.phpt
deleted file mode 100644
index 405f34a435..0000000000
--- a/ext/standard/tests/array/next_variation1.phpt
+++ /dev/null
@@ -1,219 +0,0 @@
---TEST--
-Test next() function : usage variation - Pass different data types as $array_arg
---FILE--
-<?php
-/* Prototype : mixed next(array $array_arg)
- * Description: Move array argument's internal pointer to the next element and return it
- * Source code: ext/standard/array.c
- */
-
-/*
- * Pass different data types as $array_arg argument to next() to test behaviour
- */
-
-echo "*** Testing next() : variation ***\n";
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// get a class
-class classA
-{
- public function __toString() {
- return "Class A object";
- }
-}
-
-// heredoc string
-$heredoc = <<<EOT
-hello world
-EOT;
-
-// get a resource variable
-$fp = fopen(__FILE__, "r");
-
-// unexpected values to be passed to $array_arg argument
-$inputs = array(
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 12.3456789000e10,
- 12.3456789000E-10,
- .5,
-
- // null data
-/*10*/ NULL,
- null,
-
- // boolean data
-/*12*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*16*/ "",
- '',
- array(),
-
- // string data
-/*19*/ "string",
- 'string',
- $heredoc,
-
- // object data
-/*22*/ new classA(),
-
- // undefined data
-/*23*/ @$undefined_var,
-
- // unset data
-/*24*/ @$unset_var,
-
- // resource variable
-/*25*/ $fp
-);
-
-// loop through each element of $inputs to check the behavior of next()
-$iterator = 1;
-foreach($inputs as $input) {
- echo "\n-- Iteration $iterator --\n";
- var_dump( next($input) );
- $iterator++;
-};
-
-fclose($fp);
-?>
-===DONE===
---EXPECTF--
-*** Testing next() : variation ***
-
--- Iteration 1 --
-
-Warning: next() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 2 --
-
-Warning: next() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 3 --
-
-Warning: next() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 4 --
-
-Warning: next() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 5 --
-
-Warning: next() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 6 --
-
-Warning: next() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 7 --
-
-Warning: next() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 8 --
-
-Warning: next() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 9 --
-
-Warning: next() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 10 --
-
-Warning: next() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 11 --
-
-Warning: next() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 12 --
-
-Warning: next() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 13 --
-
-Warning: next() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 14 --
-
-Warning: next() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 15 --
-
-Warning: next() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 16 --
-
-Warning: next() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 17 --
-
-Warning: next() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 18 --
-bool(false)
-
--- Iteration 19 --
-
-Warning: next() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 20 --
-
-Warning: next() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 21 --
-
-Warning: next() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 22 --
-bool(false)
-
--- Iteration 23 --
-
-Warning: next() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 24 --
-
-Warning: next() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 25 --
-
-Warning: next() expects parameter 1 to be array, resource given in %s on line %d
-NULL
-===DONE===
diff --git a/ext/standard/tests/array/prev_variation1.phpt b/ext/standard/tests/array/prev_variation1.phpt
deleted file mode 100644
index 01156d8239..0000000000
--- a/ext/standard/tests/array/prev_variation1.phpt
+++ /dev/null
@@ -1,219 +0,0 @@
---TEST--
-Test prev() function : usage variation - Pass different data types as $array_arg
---FILE--
-<?php
-/* Prototype : mixed prev(array $array_arg)
- * Description: Move array argument's internal pointer to the previous element and return it
- * Source code: ext/standard/array.c
- */
-
-/*
- * Pass different data types as $array_arg argument to prev() to test behaviour
- */
-
-echo "*** Testing prev() : variation ***\n";
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// get a class
-class classA
-{
- public function __toString() {
- return "Class A object";
- }
-}
-
-// heredoc string
-$heredoc = <<<EOT
-hello world
-EOT;
-
-// get a resource variable
-$fp = fopen(__FILE__, "r");
-
-// unexpected values to be passed to $array_arg argument
-$inputs = array(
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 12.3456789000e10,
- 12.3456789000E-10,
- .5,
-
- // null data
-/*10*/ NULL,
- null,
-
- // boolean data
-/*12*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*16*/ "",
- '',
- array(),
-
- // string data
-/*19*/ "string",
- 'string',
- $heredoc,
-
- // object data
-/*22*/ new classA(),
-
- // undefined data
-/*23*/ @$undefined_var,
-
- // unset data
-/*24*/ @$unset_var,
-
- // resource variable
-/*25*/ $fp
-);
-
-// loop through each element of $inputs to check the behavior of prev()
-$iterator = 1;
-foreach($inputs as $input) {
- echo "\n-- Iteration $iterator --\n";
- var_dump( prev($input) );
- $iterator++;
-};
-
-fclose($fp);
-?>
-===DONE===
---EXPECTF--
-*** Testing prev() : variation ***
-
--- Iteration 1 --
-
-Warning: prev() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 2 --
-
-Warning: prev() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 3 --
-
-Warning: prev() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 4 --
-
-Warning: prev() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 5 --
-
-Warning: prev() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 6 --
-
-Warning: prev() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 7 --
-
-Warning: prev() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 8 --
-
-Warning: prev() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 9 --
-
-Warning: prev() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 10 --
-
-Warning: prev() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 11 --
-
-Warning: prev() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 12 --
-
-Warning: prev() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 13 --
-
-Warning: prev() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 14 --
-
-Warning: prev() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 15 --
-
-Warning: prev() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 16 --
-
-Warning: prev() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 17 --
-
-Warning: prev() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 18 --
-bool(false)
-
--- Iteration 19 --
-
-Warning: prev() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 20 --
-
-Warning: prev() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 21 --
-
-Warning: prev() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 22 --
-bool(false)
-
--- Iteration 23 --
-
-Warning: prev() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 24 --
-
-Warning: prev() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 25 --
-
-Warning: prev() expects parameter 1 to be array, resource given in %s on line %d
-NULL
-===DONE===
diff --git a/ext/standard/tests/array/reset_variation1.phpt b/ext/standard/tests/array/reset_variation1.phpt
deleted file mode 100644
index f273324902..0000000000
--- a/ext/standard/tests/array/reset_variation1.phpt
+++ /dev/null
@@ -1,219 +0,0 @@
---TEST--
-Test reset() function : usage variations - Pass different data types as $array_arg arg.
---FILE--
-<?php
-/* Prototype : mixed reset(array $array_arg)
- * Description: Set array argument's internal pointer to the first element and return it
- * Source code: ext/standard/array.c
- */
-
-/*
- * Pass different data types as $array_arg argument to reset() to test behaviour
- */
-
-echo "*** Testing reset() : usage variations ***\n";
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// get a class
-class classA
-{
- public function __toString() {
- return "Class A object";
- }
-}
-
-// heredoc string
-$heredoc = <<<EOT
-hello world
-EOT;
-
-// get a resource variable
-$fp = fopen(__FILE__, "r");
-
-// unexpected values to be passed to $array_arg argument
-$inputs = array(
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 12.3456789000e10,
- 12.3456789000E-10,
- .5,
-
- // null data
-/*10*/ NULL,
- null,
-
- // boolean data
-/*12*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*16*/ "",
- '',
- array(),
-
- // string data
-/*19*/ "string",
- 'string',
- $heredoc,
-
- // object data
-/*22*/ new classA(),
-
- // undefined data
-/*23*/ @$undefined_var,
-
- // unset data
-/*24*/ @$unset_var,
-
- // resource variable
-/*25*/ $fp
-);
-
-// loop through each element of $inputs to check the behavior of reset()
-$iterator = 1;
-foreach($inputs as $input) {
- echo "\n-- Iteration $iterator --\n";
- var_dump( reset($input) );
- $iterator++;
-};
-
-fclose($fp);
-?>
-===DONE===
---EXPECTF--
-*** Testing reset() : usage variations ***
-
--- Iteration 1 --
-
-Warning: reset() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 2 --
-
-Warning: reset() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 3 --
-
-Warning: reset() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 4 --
-
-Warning: reset() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 5 --
-
-Warning: reset() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 6 --
-
-Warning: reset() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 7 --
-
-Warning: reset() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 8 --
-
-Warning: reset() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 9 --
-
-Warning: reset() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 10 --
-
-Warning: reset() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 11 --
-
-Warning: reset() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 12 --
-
-Warning: reset() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 13 --
-
-Warning: reset() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 14 --
-
-Warning: reset() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 15 --
-
-Warning: reset() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 16 --
-
-Warning: reset() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 17 --
-
-Warning: reset() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 18 --
-bool(false)
-
--- Iteration 19 --
-
-Warning: reset() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 20 --
-
-Warning: reset() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 21 --
-
-Warning: reset() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 22 --
-bool(false)
-
--- Iteration 23 --
-
-Warning: reset() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 24 --
-
-Warning: reset() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 25 --
-
-Warning: reset() expects parameter 1 to be array, resource given in %s on line %d
-NULL
-===DONE===
diff --git a/ext/standard/tests/array/rsort_variation1.phpt b/ext/standard/tests/array/rsort_variation1.phpt
deleted file mode 100644
index 5b83c89a29..0000000000
--- a/ext/standard/tests/array/rsort_variation1.phpt
+++ /dev/null
@@ -1,513 +0,0 @@
---TEST--
-Test rsort() function : usage variations - Pass different data types as $array_arg arg
---FILE--
-<?php
-/* Prototype : bool rsort(array &$array_arg [, int $sort_flags])
- * Description: Sort an array in reverse order
- * Source code: ext/standard/array.c
- */
-
-/*
- * Pass different data types as $array_arg argument to rsort() to test behaviour
- */
-
-echo "*** Testing rsort() : variation ***\n";
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// get a class
-class classA
-{
- public function __toString() {
- return "Class A object";
- }
-}
-
-// heredoc string
-$heredoc = <<<EOT
-hello world
-EOT;
-
-// get a resource variable
-$fp = fopen(__FILE__, "r");
-
-// unexpected values to be passed to $array_arg argument
-$inputs = array(
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 12.3456789000e10,
- 12.3456789000E-10,
- .5,
-
- // null data
-/*10*/ NULL,
- null,
-
- // boolean data
-/*12*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*16*/ "",
- '',
-
- // string data
-/*18*/ "string",
- 'string',
- $heredoc,
-
- // object data
-/*21*/ new classA(),
-
- // undefined data
-/*22*/ @$undefined_var,
-
- // unset data
-/*23*/ @$unset_var,
-
- // resource variable
-/*24*/ $fp
-);
-
-// loop through each element of $inputs to check the behavior of rsort()
-$iterator = 1;
-foreach ($inputs as $input) {
- echo "-- Iteration $iterator --\n";
- echo "Flag = default:\n";
- var_dump( rsort($input) );
- echo "Flag = SORT_REGULAR:\n";
- var_dump( rsort($input, SORT_REGULAR) );
- echo "Flag = SORT_NUMERIC:\n";
- var_dump( rsort($input, SORT_NUMERIC) );
- echo "Flag = SORT_STRING:\n";
- var_dump( rsort($input, SORT_STRING) );
- $iterator++;
-}
-
-fclose($fp);
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing rsort() : variation ***
--- Iteration 1 --
-Flag = default:
-
-Warning: rsort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-Flag = SORT_REGULAR:
-
-Warning: rsort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-Flag = SORT_NUMERIC:
-
-Warning: rsort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-Flag = SORT_STRING:
-
-Warning: rsort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
--- Iteration 2 --
-Flag = default:
-
-Warning: rsort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-Flag = SORT_REGULAR:
-
-Warning: rsort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-Flag = SORT_NUMERIC:
-
-Warning: rsort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-Flag = SORT_STRING:
-
-Warning: rsort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
--- Iteration 3 --
-Flag = default:
-
-Warning: rsort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-Flag = SORT_REGULAR:
-
-Warning: rsort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-Flag = SORT_NUMERIC:
-
-Warning: rsort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-Flag = SORT_STRING:
-
-Warning: rsort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
--- Iteration 4 --
-Flag = default:
-
-Warning: rsort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-Flag = SORT_REGULAR:
-
-Warning: rsort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-Flag = SORT_NUMERIC:
-
-Warning: rsort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-Flag = SORT_STRING:
-
-Warning: rsort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
--- Iteration 5 --
-Flag = default:
-
-Warning: rsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-Flag = SORT_REGULAR:
-
-Warning: rsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-Flag = SORT_NUMERIC:
-
-Warning: rsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-Flag = SORT_STRING:
-
-Warning: rsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
--- Iteration 6 --
-Flag = default:
-
-Warning: rsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-Flag = SORT_REGULAR:
-
-Warning: rsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-Flag = SORT_NUMERIC:
-
-Warning: rsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-Flag = SORT_STRING:
-
-Warning: rsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
--- Iteration 7 --
-Flag = default:
-
-Warning: rsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-Flag = SORT_REGULAR:
-
-Warning: rsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-Flag = SORT_NUMERIC:
-
-Warning: rsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-Flag = SORT_STRING:
-
-Warning: rsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
--- Iteration 8 --
-Flag = default:
-
-Warning: rsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-Flag = SORT_REGULAR:
-
-Warning: rsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-Flag = SORT_NUMERIC:
-
-Warning: rsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-Flag = SORT_STRING:
-
-Warning: rsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
--- Iteration 9 --
-Flag = default:
-
-Warning: rsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-Flag = SORT_REGULAR:
-
-Warning: rsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-Flag = SORT_NUMERIC:
-
-Warning: rsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-Flag = SORT_STRING:
-
-Warning: rsort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
--- Iteration 10 --
-Flag = default:
-
-Warning: rsort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-Flag = SORT_REGULAR:
-
-Warning: rsort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-Flag = SORT_NUMERIC:
-
-Warning: rsort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-Flag = SORT_STRING:
-
-Warning: rsort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
--- Iteration 11 --
-Flag = default:
-
-Warning: rsort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-Flag = SORT_REGULAR:
-
-Warning: rsort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-Flag = SORT_NUMERIC:
-
-Warning: rsort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-Flag = SORT_STRING:
-
-Warning: rsort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
--- Iteration 12 --
-Flag = default:
-
-Warning: rsort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-Flag = SORT_REGULAR:
-
-Warning: rsort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-Flag = SORT_NUMERIC:
-
-Warning: rsort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-Flag = SORT_STRING:
-
-Warning: rsort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
--- Iteration 13 --
-Flag = default:
-
-Warning: rsort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-Flag = SORT_REGULAR:
-
-Warning: rsort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-Flag = SORT_NUMERIC:
-
-Warning: rsort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-Flag = SORT_STRING:
-
-Warning: rsort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
--- Iteration 14 --
-Flag = default:
-
-Warning: rsort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-Flag = SORT_REGULAR:
-
-Warning: rsort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-Flag = SORT_NUMERIC:
-
-Warning: rsort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-Flag = SORT_STRING:
-
-Warning: rsort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
--- Iteration 15 --
-Flag = default:
-
-Warning: rsort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-Flag = SORT_REGULAR:
-
-Warning: rsort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-Flag = SORT_NUMERIC:
-
-Warning: rsort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-Flag = SORT_STRING:
-
-Warning: rsort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
--- Iteration 16 --
-Flag = default:
-
-Warning: rsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-Flag = SORT_REGULAR:
-
-Warning: rsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-Flag = SORT_NUMERIC:
-
-Warning: rsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-Flag = SORT_STRING:
-
-Warning: rsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
--- Iteration 17 --
-Flag = default:
-
-Warning: rsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-Flag = SORT_REGULAR:
-
-Warning: rsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-Flag = SORT_NUMERIC:
-
-Warning: rsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-Flag = SORT_STRING:
-
-Warning: rsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
--- Iteration 18 --
-Flag = default:
-
-Warning: rsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-Flag = SORT_REGULAR:
-
-Warning: rsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-Flag = SORT_NUMERIC:
-
-Warning: rsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-Flag = SORT_STRING:
-
-Warning: rsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
--- Iteration 19 --
-Flag = default:
-
-Warning: rsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-Flag = SORT_REGULAR:
-
-Warning: rsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-Flag = SORT_NUMERIC:
-
-Warning: rsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-Flag = SORT_STRING:
-
-Warning: rsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
--- Iteration 20 --
-Flag = default:
-
-Warning: rsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-Flag = SORT_REGULAR:
-
-Warning: rsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-Flag = SORT_NUMERIC:
-
-Warning: rsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-Flag = SORT_STRING:
-
-Warning: rsort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
--- Iteration 21 --
-Flag = default:
-
-Warning: rsort() expects parameter 1 to be array, object given in %s on line %d
-bool(false)
-Flag = SORT_REGULAR:
-
-Warning: rsort() expects parameter 1 to be array, object given in %s on line %d
-bool(false)
-Flag = SORT_NUMERIC:
-
-Warning: rsort() expects parameter 1 to be array, object given in %s on line %d
-bool(false)
-Flag = SORT_STRING:
-
-Warning: rsort() expects parameter 1 to be array, object given in %s on line %d
-bool(false)
--- Iteration 22 --
-Flag = default:
-
-Warning: rsort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-Flag = SORT_REGULAR:
-
-Warning: rsort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-Flag = SORT_NUMERIC:
-
-Warning: rsort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-Flag = SORT_STRING:
-
-Warning: rsort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
--- Iteration 23 --
-Flag = default:
-
-Warning: rsort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-Flag = SORT_REGULAR:
-
-Warning: rsort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-Flag = SORT_NUMERIC:
-
-Warning: rsort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-Flag = SORT_STRING:
-
-Warning: rsort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
--- Iteration 24 --
-Flag = default:
-
-Warning: rsort() expects parameter 1 to be array, resource given in %s on line %d
-bool(false)
-Flag = SORT_REGULAR:
-
-Warning: rsort() expects parameter 1 to be array, resource given in %s on line %d
-bool(false)
-Flag = SORT_NUMERIC:
-
-Warning: rsort() expects parameter 1 to be array, resource given in %s on line %d
-bool(false)
-Flag = SORT_STRING:
-
-Warning: rsort() expects parameter 1 to be array, resource given in %s on line %d
-bool(false)
-Done
diff --git a/ext/standard/tests/array/rsort_variation2.phpt b/ext/standard/tests/array/rsort_variation2.phpt
deleted file mode 100644
index d2b3e0e423..0000000000
--- a/ext/standard/tests/array/rsort_variation2.phpt
+++ /dev/null
@@ -1,485 +0,0 @@
---TEST--
-Test rsort() function : usage variations - Pass different data types as $sort_flags arg
---SKIPIF--
-<?php if (PHP_INT_SIZE != 8) die("skip this test is for 64-bit only");
---FILE--
-<?php
-/* Prototype : bool rsort(array &$array_arg [, int $sort_flags])
- * Description: Sort an array in reverse order
- * Source code: ext/standard/array.c
- */
-
-/*
- * Pass different data types as $sort_flags argument to rsort() to test behaviour
- * Where possible, 'SORT_NUMERIC' has been entered as a string value
- */
-
-echo "*** Testing rsort() : variation ***\n";
-
-// Initialise function arguments not being substituted
-$array_arg = array (1, 5, 2, 3, 1);
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// get a class
-class classA
-{
- public function __toString() {
- return "SORT_NUMERIC";
- }
-}
-
-// heredoc string
-$heredoc = <<<EOT
-SORT_NUMERIC
-EOT;
-
-// get a resource variable
-$fp = fopen(__FILE__, "r");
-
-// unexpected values to be passed to $sort_flags argument
-$inputs = array(
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 12.3456789000e10,
- 12.3456789000E-10,
- .5,
-
- // null data
-/*10*/ NULL,
- null,
-
- // boolean data
-/*12*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*16*/ "",
- '',
-
- // string data
-/*18*/ "SORT_NUMERIC",
- 'SORT_NUMERIC',
- $heredoc,
-
- // object data
-/*21*/ new classA(),
-
- // undefined data
-/*22*/ @$undefined_var,
-
- // unset data
-/*23*/ @$unset_var,
-
- // resource variable
-/*24*/ $fp
-);
-
-// loop through each element of $inputs to check the behavior of rsort()
-$iterator = 1;
-foreach($inputs as $input) {
- echo "\n-- Iteration $iterator --\n";
-
- //create temporary array in case rsort() works
- $temp = $array_arg;
-
- var_dump( rsort($temp, $input) );
- var_dump($temp);
- $iterator++;
-
- $temp = null;
-};
-
-fclose($fp);
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing rsort() : variation ***
-
--- Iteration 1 --
-bool(true)
-array(5) {
- [0]=>
- int(5)
- [1]=>
- int(3)
- [2]=>
- int(2)
- [3]=>
- int(1)
- [4]=>
- int(1)
-}
-
--- Iteration 2 --
-bool(true)
-array(5) {
- [0]=>
- int(5)
- [1]=>
- int(3)
- [2]=>
- int(2)
- [3]=>
- int(1)
- [4]=>
- int(1)
-}
-
--- Iteration 3 --
-bool(true)
-array(5) {
- [0]=>
- int(5)
- [1]=>
- int(3)
- [2]=>
- int(2)
- [3]=>
- int(1)
- [4]=>
- int(1)
-}
-
--- Iteration 4 --
-bool(true)
-array(5) {
- [0]=>
- int(5)
- [1]=>
- int(3)
- [2]=>
- int(2)
- [3]=>
- int(1)
- [4]=>
- int(1)
-}
-
--- Iteration 5 --
-bool(true)
-array(5) {
- [0]=>
- int(5)
- [1]=>
- int(3)
- [2]=>
- int(2)
- [3]=>
- int(1)
- [4]=>
- int(1)
-}
-
--- Iteration 6 --
-bool(true)
-array(5) {
- [0]=>
- int(5)
- [1]=>
- int(3)
- [2]=>
- int(2)
- [3]=>
- int(1)
- [4]=>
- int(1)
-}
-
--- Iteration 7 --
-bool(true)
-array(5) {
- [0]=>
- int(5)
- [1]=>
- int(3)
- [2]=>
- int(2)
- [3]=>
- int(1)
- [4]=>
- int(1)
-}
-
--- Iteration 8 --
-bool(true)
-array(5) {
- [0]=>
- int(5)
- [1]=>
- int(3)
- [2]=>
- int(2)
- [3]=>
- int(1)
- [4]=>
- int(1)
-}
-
--- Iteration 9 --
-bool(true)
-array(5) {
- [0]=>
- int(5)
- [1]=>
- int(3)
- [2]=>
- int(2)
- [3]=>
- int(1)
- [4]=>
- int(1)
-}
-
--- Iteration 10 --
-bool(true)
-array(5) {
- [0]=>
- int(5)
- [1]=>
- int(3)
- [2]=>
- int(2)
- [3]=>
- int(1)
- [4]=>
- int(1)
-}
-
--- Iteration 11 --
-bool(true)
-array(5) {
- [0]=>
- int(5)
- [1]=>
- int(3)
- [2]=>
- int(2)
- [3]=>
- int(1)
- [4]=>
- int(1)
-}
-
--- Iteration 12 --
-bool(true)
-array(5) {
- [0]=>
- int(5)
- [1]=>
- int(3)
- [2]=>
- int(2)
- [3]=>
- int(1)
- [4]=>
- int(1)
-}
-
--- Iteration 13 --
-bool(true)
-array(5) {
- [0]=>
- int(5)
- [1]=>
- int(3)
- [2]=>
- int(2)
- [3]=>
- int(1)
- [4]=>
- int(1)
-}
-
--- Iteration 14 --
-bool(true)
-array(5) {
- [0]=>
- int(5)
- [1]=>
- int(3)
- [2]=>
- int(2)
- [3]=>
- int(1)
- [4]=>
- int(1)
-}
-
--- Iteration 15 --
-bool(true)
-array(5) {
- [0]=>
- int(5)
- [1]=>
- int(3)
- [2]=>
- int(2)
- [3]=>
- int(1)
- [4]=>
- int(1)
-}
-
--- Iteration 16 --
-
-Warning: rsort() expects parameter 2 to be int, string given in %s on line %d
-bool(false)
-array(5) {
- [0]=>
- int(1)
- [1]=>
- int(5)
- [2]=>
- int(2)
- [3]=>
- int(3)
- [4]=>
- int(1)
-}
-
--- Iteration 17 --
-
-Warning: rsort() expects parameter 2 to be int, string given in %s on line %d
-bool(false)
-array(5) {
- [0]=>
- int(1)
- [1]=>
- int(5)
- [2]=>
- int(2)
- [3]=>
- int(3)
- [4]=>
- int(1)
-}
-
--- Iteration 18 --
-
-Warning: rsort() expects parameter 2 to be int, string given in %s on line %d
-bool(false)
-array(5) {
- [0]=>
- int(1)
- [1]=>
- int(5)
- [2]=>
- int(2)
- [3]=>
- int(3)
- [4]=>
- int(1)
-}
-
--- Iteration 19 --
-
-Warning: rsort() expects parameter 2 to be int, string given in %s on line %d
-bool(false)
-array(5) {
- [0]=>
- int(1)
- [1]=>
- int(5)
- [2]=>
- int(2)
- [3]=>
- int(3)
- [4]=>
- int(1)
-}
-
--- Iteration 20 --
-
-Warning: rsort() expects parameter 2 to be int, string given in %s on line %d
-bool(false)
-array(5) {
- [0]=>
- int(1)
- [1]=>
- int(5)
- [2]=>
- int(2)
- [3]=>
- int(3)
- [4]=>
- int(1)
-}
-
--- Iteration 21 --
-
-Warning: rsort() expects parameter 2 to be int, object given in %s on line %d
-bool(false)
-array(5) {
- [0]=>
- int(1)
- [1]=>
- int(5)
- [2]=>
- int(2)
- [3]=>
- int(3)
- [4]=>
- int(1)
-}
-
--- Iteration 22 --
-bool(true)
-array(5) {
- [0]=>
- int(5)
- [1]=>
- int(3)
- [2]=>
- int(2)
- [3]=>
- int(1)
- [4]=>
- int(1)
-}
-
--- Iteration 23 --
-bool(true)
-array(5) {
- [0]=>
- int(5)
- [1]=>
- int(3)
- [2]=>
- int(2)
- [3]=>
- int(1)
- [4]=>
- int(1)
-}
-
--- Iteration 24 --
-
-Warning: rsort() expects parameter 2 to be int, resource given in %s on line %d
-bool(false)
-array(5) {
- [0]=>
- int(1)
- [1]=>
- int(5)
- [2]=>
- int(2)
- [3]=>
- int(3)
- [4]=>
- int(1)
-}
-Done
diff --git a/ext/standard/tests/array/shuffle_variation1.phpt b/ext/standard/tests/array/shuffle_variation1.phpt
deleted file mode 100644
index 3c0ab5051a..0000000000
--- a/ext/standard/tests/array/shuffle_variation1.phpt
+++ /dev/null
@@ -1,213 +0,0 @@
---TEST--
-Test shuffle() function : usage variations - unexpected values for 'array_arg' argument
---FILE--
-<?php
-/* Prototype : bool shuffle(array $array_arg)
- * Description: Randomly shuffle the contents of an array
- * Source code: ext/standard/array.c
-*/
-
-/*
-* Test behaviour of shuffle() when unexpected values are passed for 'array_arg'
-* argument and verify that function outputs required warning messages wherever applicable
-*/
-
-echo "*** Testing shuffle() : with unexpected values for 'array_arg' argument ***\n";
-
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-//get a resource variable
-$fp = fopen(__FILE__, "r");
-
-//define a class
-class test
-{
- var $t = 10;
- function __toString()
- {
- return "object";
- }
-}
-
-//array of values to iterate over
-$values = array(
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 12.3456789000e10,
- 12.3456789000E-10,
- .5,
-
- // null data
-/*10*/ NULL,
- null,
-
- // boolean data
-/*12*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*16*/ "",
- '',
-
- // string data
-/*18*/ "string",
- 'string',
-
- // object data
-/*20*/ new test(),
-
- // undefined data
-/*21*/ @$undefined_var,
-
- // unset data
-/*22*/ @$unset_var,
-
-/*23*/ // resource data
- $fp
-);
-
-// loop through the array to test shuffle() function
-// with each element of the array
-$count = 1;
-foreach($values as $value) {
- echo "\n-- Iteration $count --\n";
- var_dump( shuffle($value) );
- $count++;
-};
-
-// closing the resource
-fclose($fp);
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing shuffle() : with unexpected values for 'array_arg' argument ***
-
--- Iteration 1 --
-
-Warning: shuffle() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
--- Iteration 2 --
-
-Warning: shuffle() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
--- Iteration 3 --
-
-Warning: shuffle() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
--- Iteration 4 --
-
-Warning: shuffle() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
--- Iteration 5 --
-
-Warning: shuffle() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
--- Iteration 6 --
-
-Warning: shuffle() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
--- Iteration 7 --
-
-Warning: shuffle() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
--- Iteration 8 --
-
-Warning: shuffle() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
--- Iteration 9 --
-
-Warning: shuffle() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
--- Iteration 10 --
-
-Warning: shuffle() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-
--- Iteration 11 --
-
-Warning: shuffle() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-
--- Iteration 12 --
-
-Warning: shuffle() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
--- Iteration 13 --
-
-Warning: shuffle() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
--- Iteration 14 --
-
-Warning: shuffle() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
--- Iteration 15 --
-
-Warning: shuffle() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
--- Iteration 16 --
-
-Warning: shuffle() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
--- Iteration 17 --
-
-Warning: shuffle() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
--- Iteration 18 --
-
-Warning: shuffle() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
--- Iteration 19 --
-
-Warning: shuffle() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
--- Iteration 20 --
-
-Warning: shuffle() expects parameter 1 to be array, object given in %s on line %d
-bool(false)
-
--- Iteration 21 --
-
-Warning: shuffle() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-
--- Iteration 22 --
-
-Warning: shuffle() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-
--- Iteration 23 --
-
-Warning: shuffle() expects parameter 1 to be array, resource given in %s on line %d
-bool(false)
-Done
diff --git a/ext/standard/tests/array/sort_variation1.phpt b/ext/standard/tests/array/sort_variation1.phpt
deleted file mode 100644
index 9eca22c680..0000000000
--- a/ext/standard/tests/array/sort_variation1.phpt
+++ /dev/null
@@ -1,398 +0,0 @@
---TEST--
-Test sort() function : usage variations - unexpected values for 'array_arg' argument
---FILE--
-<?php
-/* Prototype : bool sort(array &array_arg [, int $sort_flags])
- * Description: Sort an array
- * Source code: ext/standard/array.c
-*/
-
-/*
- * testing sort() by providing different unexpected values for array argument
- * with following flag values.
- * 1. flag value as defualt
- * 2. SORT_REGULAR - compare items normally
- * 3. SORT_NUMERIC - compare items numerically
- * 4. SORT_STRING - compare items as strings
-*/
-
-echo "*** Testing sort() : usage variations ***\n";
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// resource variable
-$fp = fopen(__FILE__, "r");
-
-//array of values to iterate over
-$unexpected_values = array (
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 10.5e3,
- 10.6E-2,
- .5,
-
- // null data
-/*10*/ NULL,
- null,
-
- // boolean data
-/*12*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*16*/ "",
- '',
-
- // string data
-/*18*/ "string",
- 'string',
-
- // object data
-/*20*/ new stdclass(),
-
- // undefined data
-/*21*/ @undefined_var,
-
- // unset data
-/*22*/ @unset_var,
-
- // resource variable
-/*23*/ $fp
-);
-
-// loop though each element of the array and check the working of sort()
-// when $array argument is supplied with different values from $unexpected_values
-echo "\n-- Testing sort() by supplying different unexpected values for 'array' argument --\n";
-echo "\n-- Flag values are defualt, SORT_REGULAR, SORT_NUMERIC, SORT_STRING --\n";
-
-$counter = 1;
-for($index = 0; $index < count($unexpected_values); $index ++) {
- echo "-- Iteration $counter --\n";
- $value = $unexpected_values [$index];
- var_dump( sort($value) ); // expecting : bool(false)
- var_dump( sort($value, SORT_REGULAR) ); // expecting : bool(false)
- var_dump( sort($value, SORT_NUMERIC) ); // expecting : bool(false)
- var_dump( sort($value, SORT_STRING) ); // expecting : bool(false)
- $counter++;
-}
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing sort() : usage variations ***
-
--- Testing sort() by supplying different unexpected values for 'array' argument --
-
--- Flag values are defualt, SORT_REGULAR, SORT_NUMERIC, SORT_STRING --
--- Iteration 1 --
-
-Warning: sort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
--- Iteration 2 --
-
-Warning: sort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
--- Iteration 3 --
-
-Warning: sort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
--- Iteration 4 --
-
-Warning: sort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, int given in %s on line %d
-bool(false)
--- Iteration 5 --
-
-Warning: sort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
--- Iteration 6 --
-
-Warning: sort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
--- Iteration 7 --
-
-Warning: sort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
--- Iteration 8 --
-
-Warning: sort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
--- Iteration 9 --
-
-Warning: sort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, float given in %s on line %d
-bool(false)
--- Iteration 10 --
-
-Warning: sort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
--- Iteration 11 --
-
-Warning: sort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, null given in %s on line %d
-bool(false)
--- Iteration 12 --
-
-Warning: sort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
--- Iteration 13 --
-
-Warning: sort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
--- Iteration 14 --
-
-Warning: sort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
--- Iteration 15 --
-
-Warning: sort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, bool given in %s on line %d
-bool(false)
--- Iteration 16 --
-
-Warning: sort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
--- Iteration 17 --
-
-Warning: sort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
--- Iteration 18 --
-
-Warning: sort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
--- Iteration 19 --
-
-Warning: sort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
--- Iteration 20 --
-
-Warning: sort() expects parameter 1 to be array, object given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, object given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, object given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, object given in %s on line %d
-bool(false)
--- Iteration 21 --
-
-Warning: sort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
--- Iteration 22 --
-
-Warning: sort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, string given in %s on line %d
-bool(false)
--- Iteration 23 --
-
-Warning: sort() expects parameter 1 to be array, resource given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, resource given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, resource given in %s on line %d
-bool(false)
-
-Warning: sort() expects parameter 1 to be array, resource given in %s on line %d
-bool(false)
-Done
diff --git a/ext/standard/tests/array/sort_variation2.phpt b/ext/standard/tests/array/sort_variation2.phpt
deleted file mode 100644
index 02e6af21af..0000000000
--- a/ext/standard/tests/array/sort_variation2.phpt
+++ /dev/null
@@ -1,311 +0,0 @@
---TEST--
-Test sort() function : usage variations - unexpected values for 'sort_flags' argument
---FILE--
-<?php
-/* Prototype : bool sort(array &array_arg [, int $sort_flags])
- * Description: Sort an array
- * Source code: ext/standard/array.c
-*/
-
-/*
- * Testing sort() by providing different unexpected values for flag argument
-*/
-
-echo "*** Testing sort() : usage variations ***\n";
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// resource variable
-$fp = fopen(__FILE__, "r");
-
-// temperory array for checking unexpected behavior
-$unsorted_values = array(10, 2, 45);
-
-//array of values to iterate over
-$unexpected_values = array(
-
- // int data
-/*1*/ -2345,
-
- // float data
-/*2*/ 10.5,
- -10.5,
- 10.5e2,
- 10.6E-2,
- .5,
-
- // null data
-/*7*/ NULL,
- null,
-
- // boolean data
-/*9*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*13*/ "",
- '',
-
- // string data
-/*15*/ "string",
- 'string',
-
- // object data
-/*16*/ new stdclass(),
-
- // undefined data
-/*17*/ @undefined_var,
-
- // unset data
-/*18*/ @unset_var,
-
- // resource variable
-/*19*/ $fp
-
-);
-
-// loop though each element of the array and check the working of sort()
-// when $flag argument is supplied with different values
-echo "\n-- Testing sort() by supplying different unexpected values for 'flag' argument --\n";
-
-$counter = 1;
-for($index = 0; $index < count($unexpected_values); $index ++) {
- echo "-- Iteration $counter --\n";
-
- // sort the array, retain a temp. copy of input array for next iteration
- $value = $unexpected_values [$index];
- $temp_array = $unsorted_values;
- var_dump( sort($temp_array, $value) );
-
- //dump the sorted array
- var_dump($temp_array);
- $counter++;
-}
-
-echo "Done";
-?>
---EXPECTF--
-*** Testing sort() : usage variations ***
-
--- Testing sort() by supplying different unexpected values for 'flag' argument --
--- Iteration 1 --
-bool(true)
-array(3) {
- [0]=>
- int(2)
- [1]=>
- int(10)
- [2]=>
- int(45)
-}
--- Iteration 2 --
-bool(true)
-array(3) {
- [0]=>
- int(10)
- [1]=>
- int(2)
- [2]=>
- int(45)
-}
--- Iteration 3 --
-bool(true)
-array(3) {
- [0]=>
- int(2)
- [1]=>
- int(10)
- [2]=>
- int(45)
-}
--- Iteration 4 --
-bool(true)
-array(3) {
- [0]=>
- int(2)
- [1]=>
- int(10)
- [2]=>
- int(45)
-}
--- Iteration 5 --
-bool(true)
-array(3) {
- [0]=>
- int(2)
- [1]=>
- int(10)
- [2]=>
- int(45)
-}
--- Iteration 6 --
-bool(true)
-array(3) {
- [0]=>
- int(2)
- [1]=>
- int(10)
- [2]=>
- int(45)
-}
--- Iteration 7 --
-bool(true)
-array(3) {
- [0]=>
- int(2)
- [1]=>
- int(10)
- [2]=>
- int(45)
-}
--- Iteration 8 --
-bool(true)
-array(3) {
- [0]=>
- int(2)
- [1]=>
- int(10)
- [2]=>
- int(45)
-}
--- Iteration 9 --
-bool(true)
-array(3) {
- [0]=>
- int(2)
- [1]=>
- int(10)
- [2]=>
- int(45)
-}
--- Iteration 10 --
-bool(true)
-array(3) {
- [0]=>
- int(2)
- [1]=>
- int(10)
- [2]=>
- int(45)
-}
--- Iteration 11 --
-bool(true)
-array(3) {
- [0]=>
- int(2)
- [1]=>
- int(10)
- [2]=>
- int(45)
-}
--- Iteration 12 --
-bool(true)
-array(3) {
- [0]=>
- int(2)
- [1]=>
- int(10)
- [2]=>
- int(45)
-}
--- Iteration 13 --
-
-Warning: sort() expects parameter 2 to be int, string given in %s on line %d
-bool(false)
-array(3) {
- [0]=>
- int(10)
- [1]=>
- int(2)
- [2]=>
- int(45)
-}
--- Iteration 14 --
-
-Warning: sort() expects parameter 2 to be int, string given in %s on line %d
-bool(false)
-array(3) {
- [0]=>
- int(10)
- [1]=>
- int(2)
- [2]=>
- int(45)
-}
--- Iteration 15 --
-
-Warning: sort() expects parameter 2 to be int, string given in %s on line %d
-bool(false)
-array(3) {
- [0]=>
- int(10)
- [1]=>
- int(2)
- [2]=>
- int(45)
-}
--- Iteration 16 --
-
-Warning: sort() expects parameter 2 to be int, string given in %s on line %d
-bool(false)
-array(3) {
- [0]=>
- int(10)
- [1]=>
- int(2)
- [2]=>
- int(45)
-}
--- Iteration 17 --
-
-Warning: sort() expects parameter 2 to be int, object given in %s on line %d
-bool(false)
-array(3) {
- [0]=>
- int(10)
- [1]=>
- int(2)
- [2]=>
- int(45)
-}
--- Iteration 18 --
-
-Warning: sort() expects parameter 2 to be int, string given in %s on line %d
-bool(false)
-array(3) {
- [0]=>
- int(10)
- [1]=>
- int(2)
- [2]=>
- int(45)
-}
--- Iteration 19 --
-
-Warning: sort() expects parameter 2 to be int, string given in %s on line %d
-bool(false)
-array(3) {
- [0]=>
- int(10)
- [1]=>
- int(2)
- [2]=>
- int(45)
-}
--- Iteration 20 --
-
-Warning: sort() expects parameter 2 to be int, resource given in %s on line %d
-bool(false)
-array(3) {
- [0]=>
- int(10)
- [1]=>
- int(2)
- [2]=>
- int(45)
-}
-Done
diff --git a/ext/standard/tests/array/uasort_variation1.phpt b/ext/standard/tests/array/uasort_variation1.phpt
deleted file mode 100644
index f3a849b938..0000000000
--- a/ext/standard/tests/array/uasort_variation1.phpt
+++ /dev/null
@@ -1,188 +0,0 @@
---TEST--
-Test uasort() function : usage variations - unexpected values for 'array_arg' argument
---FILE--
-<?php
-/* Prototype : bool uasort(array $array_arg, string $cmp_function)
- * Description: Sort an array with a user-defined comparison function and maintain index association
- * Source code: ext/standard/array.c
-*/
-
-/*
-* Testing uasort() function by passing different scalar/nonscalar values as 'array_arg' argument
-*/
-
-echo "*** Testing uasort() : unexpected values for 'array_arg' ***\n";
-
-// Comparison function
-/* Prototype : int cmp_function(mixed $value1, mixed $value2)
- * Parameters : $value1 and $value2 - values to be compared
- * Return value : 0 - if both values are same
- * 1 - if value1 is greater than value2
- * -1 - if value1 is less than value2
- * Description : compares value1 and value2
- */
-function cmp_function($value1, $value2)
-{
- if($value1 == $value2) {
- return 0;
- }
- else if($value1 > $value2) {
- return 1;
- }
- else {
- return -1;
- }
-}
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// get resource variable
-$fp = fopen(__FILE__,'r');
-
-//array of values to iterate over
-$input_values = array(
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 10.1234567e8,
- 10.7654321E-8,
- .5,
-
- // null data
-/*10*/ NULL,
- null,
-
- // boolean data
-/*12*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*16*/ "",
- '',
-
- // string data
-/*18*/ "string",
- 'string',
-
- // resource data
-/*20*/ $fp,
-
- // undefined data
- @$undefined_var,
-
- // unset data
-/*22*/ @$unset_var,
-);
-
-// loop through each value of input_values
-for($count = 0; $count < count($input_values); $count++) {
- echo "-- Iteration ".($count + 1)." --\n";
- var_dump( uasort($input_values[$count], 'cmp_function') );
-};
-
-//closing resource
-fclose($fp);
-echo "Done"
-?>
---EXPECTF--
-*** Testing uasort() : unexpected values for 'array_arg' ***
--- Iteration 1 --
-
-Warning: uasort() expects parameter 1 to be array, int given in %s on line %d
-NULL
--- Iteration 2 --
-
-Warning: uasort() expects parameter 1 to be array, int given in %s on line %d
-NULL
--- Iteration 3 --
-
-Warning: uasort() expects parameter 1 to be array, int given in %s on line %d
-NULL
--- Iteration 4 --
-
-Warning: uasort() expects parameter 1 to be array, int given in %s on line %d
-NULL
--- Iteration 5 --
-
-Warning: uasort() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 6 --
-
-Warning: uasort() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 7 --
-
-Warning: uasort() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 8 --
-
-Warning: uasort() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 9 --
-
-Warning: uasort() expects parameter 1 to be array, float given in %s on line %d
-NULL
--- Iteration 10 --
-
-Warning: uasort() expects parameter 1 to be array, null given in %s on line %d
-NULL
--- Iteration 11 --
-
-Warning: uasort() expects parameter 1 to be array, null given in %s on line %d
-NULL
--- Iteration 12 --
-
-Warning: uasort() expects parameter 1 to be array, bool given in %s on line %d
-NULL
--- Iteration 13 --
-
-Warning: uasort() expects parameter 1 to be array, bool given in %s on line %d
-NULL
--- Iteration 14 --
-
-Warning: uasort() expects parameter 1 to be array, bool given in %s on line %d
-NULL
--- Iteration 15 --
-
-Warning: uasort() expects parameter 1 to be array, bool given in %s on line %d
-NULL
--- Iteration 16 --
-
-Warning: uasort() expects parameter 1 to be array, string given in %s on line %d
-NULL
--- Iteration 17 --
-
-Warning: uasort() expects parameter 1 to be array, string given in %s on line %d
-NULL
--- Iteration 18 --
-
-Warning: uasort() expects parameter 1 to be array, string given in %s on line %d
-NULL
--- Iteration 19 --
-
-Warning: uasort() expects parameter 1 to be array, string given in %s on line %d
-NULL
--- Iteration 20 --
-
-Warning: uasort() expects parameter 1 to be array, resource given in %s on line %d
-NULL
--- Iteration 21 --
-
-Warning: uasort() expects parameter 1 to be array, null given in %s on line %d
-NULL
--- Iteration 22 --
-
-Warning: uasort() expects parameter 1 to be array, null given in %s on line %d
-NULL
-Done
diff --git a/ext/standard/tests/array/uasort_variation2.phpt b/ext/standard/tests/array/uasort_variation2.phpt
deleted file mode 100644
index e5278fbab7..0000000000
--- a/ext/standard/tests/array/uasort_variation2.phpt
+++ /dev/null
@@ -1,212 +0,0 @@
---TEST--
-Test uasort() function : usage variations - unexpected values for 'cmp_function' argument
---FILE--
-<?php
-/* Prototype : bool uasort(array $array_arg, string $cmp_function)
- * Description: Sort an array with a user-defined comparison function and maintain index association
- * Source code: ext/standard/array.c
-*/
-
-/*
-* Testing uasort() function with different scalar and nonscalar values in place of 'cmp_function'
-*/
-
-echo "*** Testing uasort() : Unexpected values in place of comparison function ***\n";
-
-// Class definition for object variable
-class MyClass
-{
- public function __toString()
- {
- return 'object';
- }
-}
-
-$array_arg = array(0 => 1, 1 => -1, 2 => 3, 3 => 10, 4 => 4, 5 => 2, 6 => 8, 7 => 5);
-
-// Get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// Get resource variable
-$fp = fopen(__FILE__,'r');
-
-// different values for 'cmp_function'
-$cmp_values = array(
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 10.1234567e8,
- 10.7654321E-8,
- .5,
-
- // array data
-/*10*/ array(),
- array(0),
- array(1),
- array(1, 2),
- array('color' => 'red', 'item' => 'pen'),
-
- // null data
-/*15*/ NULL,
- null,
-
- // boolean data
-/*17*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*21*/ "",
- '',
-
- // string data
- "string",
- 'string',
-
- // object data
-/*25*/ new MyClass(),
-
- // resource data
- $fp,
-
- // undefined data
- @$undefined_var,
-
- // unset data
-/*28*/ @$unset_var,
-);
-
-// loop through each element of the cmp_values for 'cmp_function'
-for($count = 0; $count < count($cmp_values); $count++) {
- echo "-- Iteration ".($count + 1)." --\n";
- var_dump( uasort($array_arg, $cmp_values[$count]) );
-};
-
-//closing resource
-fclose($fp);
-echo "Done"
-?>
---EXPECTF--
-*** Testing uasort() : Unexpected values in place of comparison function ***
--- Iteration 1 --
-
-Warning: uasort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 2 --
-
-Warning: uasort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 3 --
-
-Warning: uasort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 4 --
-
-Warning: uasort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 5 --
-
-Warning: uasort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 6 --
-
-Warning: uasort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 7 --
-
-Warning: uasort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 8 --
-
-Warning: uasort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 9 --
-
-Warning: uasort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 10 --
-
-Warning: uasort() expects parameter 2 to be a valid callback, array must have exactly two members in %s on line %d
-NULL
--- Iteration 11 --
-
-Warning: uasort() expects parameter 2 to be a valid callback, array must have exactly two members in %s on line %d
-NULL
--- Iteration 12 --
-
-Warning: uasort() expects parameter 2 to be a valid callback, array must have exactly two members in %s on line %d
-NULL
--- Iteration 13 --
-
-Warning: uasort() expects parameter 2 to be a valid callback, first array member is not a valid class name or object in %s on line %d
-NULL
--- Iteration 14 --
-
-Warning: uasort() expects parameter 2 to be a valid callback, first array member is not a valid class name or object in %s on line %d
-NULL
--- Iteration 15 --
-
-Warning: uasort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 16 --
-
-Warning: uasort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 17 --
-
-Warning: uasort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 18 --
-
-Warning: uasort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 19 --
-
-Warning: uasort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 20 --
-
-Warning: uasort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 21 --
-
-Warning: uasort() expects parameter 2 to be a valid callback, function '' not found or invalid function name in %s on line %d
-NULL
--- Iteration 22 --
-
-Warning: uasort() expects parameter 2 to be a valid callback, function '' not found or invalid function name in %s on line %d
-NULL
--- Iteration 23 --
-
-Warning: uasort() expects parameter 2 to be a valid callback, function 'string' not found or invalid function name in %s on line %d
-NULL
--- Iteration 24 --
-
-Warning: uasort() expects parameter 2 to be a valid callback, function 'string' not found or invalid function name in %s on line %d
-NULL
--- Iteration 25 --
-
-Warning: uasort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 26 --
-
-Warning: uasort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 27 --
-
-Warning: uasort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
--- Iteration 28 --
-
-Warning: uasort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-Done
diff --git a/ext/standard/tests/array/uksort_variation1.phpt b/ext/standard/tests/array/uksort_variation1.phpt
deleted file mode 100644
index 21210dee7b..0000000000
--- a/ext/standard/tests/array/uksort_variation1.phpt
+++ /dev/null
@@ -1,224 +0,0 @@
---TEST--
-Test uksort() function : usage variation
---FILE--
-<?php
-/* Prototype : bool uksort(array array_arg, string cmp_function)
- * Description: Sort an array by keys using a user-defined comparison function
- * Source code: ext/standard/array.c
- * Alias to functions:
- */
-
-echo "*** Testing uksort() : usage variation ***\n";
-
-// Initialise function arguments not being substituted (if any)
-$cmp_function = 'string_val';
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// define some classes
-class classWithToString
-{
- public function __toString() {
- return "Class A object";
- }
-}
-
-class classWithoutToString
-{
-}
-
-// heredoc string
-$heredoc = <<<EOT
-hello world
-EOT;
-
-// add arrays
-$index_array = array (1, 2, 3);
-$assoc_array = array ('one' => 1, 'two' => 2);
-
-//array of values to iterate over
-$inputs = array(
-
- // int data
- 'int 0' => 0,
- 'int 1' => 1,
- 'int 12345' => 12345,
- 'int -12345' => -2345,
-
- // float data
- 'float 10.5' => 10.5,
- 'float -10.5' => -10.5,
- 'float 12.3456789000e10' => 12.3456789000e10,
- 'float -12.3456789000e10' => -12.3456789000e10,
- 'float .5' => .5,
-
- // null data
- 'uppercase NULL' => NULL,
- 'lowercase null' => null,
-
- // boolean data
- 'lowercase true' => true,
- 'lowercase false' =>false,
- 'uppercase TRUE' =>TRUE,
- 'uppercase FALSE' =>FALSE,
-
- // empty data
- 'empty string DQ' => "",
- 'empty string SQ' => '',
-
- // string data
- 'string DQ' => "string",
- 'string SQ' => 'string',
- 'mixed case string' => "sTrInG",
- 'heredoc' => $heredoc,
-
- // object data
- 'instance of classWithToString' => new classWithToString(),
- 'instance of classWithoutToString' => new classWithoutToString(),
-
- // undefined data
- 'undefined var' => @$undefined_var,
-
- // unset data
- 'unset var' => @$unset_var,
-);
-
-// loop through each element of the array for array_arg
-
-foreach($inputs as $key =>$value) {
- echo "\n--$key--\n";
- var_dump( uksort($value, $cmp_function) );
-};
-
-?>
-===DONE===
---EXPECTF--
-*** Testing uksort() : usage variation ***
-
---int 0--
-
-Warning: uksort() expects parameter 1 to be array, int given in %suksort_variation1.php on line %d
-NULL
-
---int 1--
-
-Warning: uksort() expects parameter 1 to be array, int given in %suksort_variation1.php on line %d
-NULL
-
---int 12345--
-
-Warning: uksort() expects parameter 1 to be array, int given in %suksort_variation1.php on line %d
-NULL
-
---int -12345--
-
-Warning: uksort() expects parameter 1 to be array, int given in %suksort_variation1.php on line %d
-NULL
-
---float 10.5--
-
-Warning: uksort() expects parameter 1 to be array, float given in %suksort_variation1.php on line %d
-NULL
-
---float -10.5--
-
-Warning: uksort() expects parameter 1 to be array, float given in %suksort_variation1.php on line %d
-NULL
-
---float 12.3456789000e10--
-
-Warning: uksort() expects parameter 1 to be array, float given in %suksort_variation1.php on line %d
-NULL
-
---float -12.3456789000e10--
-
-Warning: uksort() expects parameter 1 to be array, float given in %suksort_variation1.php on line %d
-NULL
-
---float .5--
-
-Warning: uksort() expects parameter 1 to be array, float given in %suksort_variation1.php on line %d
-NULL
-
---uppercase NULL--
-
-Warning: uksort() expects parameter 1 to be array, null given in %suksort_variation1.php on line %d
-NULL
-
---lowercase null--
-
-Warning: uksort() expects parameter 1 to be array, null given in %suksort_variation1.php on line %d
-NULL
-
---lowercase true--
-
-Warning: uksort() expects parameter 1 to be array, bool given in %suksort_variation1.php on line %d
-NULL
-
---lowercase false--
-
-Warning: uksort() expects parameter 1 to be array, bool given in %suksort_variation1.php on line %d
-NULL
-
---uppercase TRUE--
-
-Warning: uksort() expects parameter 1 to be array, bool given in %suksort_variation1.php on line %d
-NULL
-
---uppercase FALSE--
-
-Warning: uksort() expects parameter 1 to be array, bool given in %suksort_variation1.php on line %d
-NULL
-
---empty string DQ--
-
-Warning: uksort() expects parameter 1 to be array, string given in %suksort_variation1.php on line %d
-NULL
-
---empty string SQ--
-
-Warning: uksort() expects parameter 1 to be array, string given in %suksort_variation1.php on line %d
-NULL
-
---string DQ--
-
-Warning: uksort() expects parameter 1 to be array, string given in %suksort_variation1.php on line %d
-NULL
-
---string SQ--
-
-Warning: uksort() expects parameter 1 to be array, string given in %suksort_variation1.php on line %d
-NULL
-
---mixed case string--
-
-Warning: uksort() expects parameter 1 to be array, string given in %suksort_variation1.php on line %d
-NULL
-
---heredoc--
-
-Warning: uksort() expects parameter 1 to be array, string given in %suksort_variation1.php on line %d
-NULL
-
---instance of classWithToString--
-
-Warning: uksort() expects parameter 1 to be array, object given in %suksort_variation1.php on line %d
-NULL
-
---instance of classWithoutToString--
-
-Warning: uksort() expects parameter 1 to be array, object given in %suksort_variation1.php on line %d
-NULL
-
---undefined var--
-
-Warning: uksort() expects parameter 1 to be array, null given in %suksort_variation1.php on line %d
-NULL
-
---unset var--
-
-Warning: uksort() expects parameter 1 to be array, null given in %suksort_variation1.php on line %d
-NULL
-===DONE===
diff --git a/ext/standard/tests/array/uksort_variation2.phpt b/ext/standard/tests/array/uksort_variation2.phpt
deleted file mode 100644
index 5ac32f02b8..0000000000
--- a/ext/standard/tests/array/uksort_variation2.phpt
+++ /dev/null
@@ -1,224 +0,0 @@
---TEST--
-Test uksort() function : usage variation
---FILE--
-<?php
-/* Prototype : bool uksort(array array_arg, string cmp_function)
- * Description: Sort an array by keys using a user-defined comparison function
- * Source code: ext/standard/array.c
- * Alias to functions:
- */
-
-echo "*** Testing uksort() : usage variation ***\n";
-
-// Initialise function arguments not being substituted (if any)
-$array_arg = array(1, 2);
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// define some classes
-class classWithToString
-{
- public function __toString() {
- return "Class A object";
- }
-}
-
-class classWithoutToString
-{
-}
-
-// heredoc string
-$heredoc = <<<EOT
-hello world
-EOT;
-
-// add arrays
-$index_array = array (1, 2, 3);
-$assoc_array = array ('one' => 1, 'two' => 2);
-
-//array of values to iterate over
-$inputs = array(
-
- // int data
- 'int 0' => 0,
- 'int 1' => 1,
- 'int 12345' => 12345,
- 'int -12345' => -2345,
-
- // float data
- 'float 10.5' => 10.5,
- 'float -10.5' => -10.5,
- 'float 12.3456789000e10' => 12.3456789000e10,
- 'float -12.3456789000e10' => -12.3456789000e10,
- 'float .5' => .5,
-
- // array data
- 'empty array' => array(),
- 'int indexed array' => $index_array,
- 'associative array' => $assoc_array,
- 'nested arrays' => array('foo', $index_array, $assoc_array),
-
- // null data
- 'uppercase NULL' => NULL,
- 'lowercase null' => null,
-
- // boolean data
- 'lowercase true' => true,
- 'lowercase false' =>false,
- 'uppercase TRUE' =>TRUE,
- 'uppercase FALSE' =>FALSE,
-
- // empty data
- 'empty string DQ' => "",
- 'empty string SQ' => '',
-
- // object data
- 'instance of classWithToString' => new classWithToString(),
- 'instance of classWithoutToString' => new classWithoutToString(),
-
- // undefined data
- 'undefined var' => @$undefined_var,
-
- // unset data
- 'unset var' => @$unset_var,
-);
-
-// loop through each element of the array for cmp_function
-
-foreach($inputs as $key =>$value) {
- echo "\n--$key--\n";
- var_dump( uksort($array_arg, $value) );
-};
-
-?>
-===DONE===
---EXPECTF--
-*** Testing uksort() : usage variation ***
-
---int 0--
-
-Warning: uksort() expects parameter 2 to be a valid callback, no array or string given in %suksort_variation2.php on line %d
-NULL
-
---int 1--
-
-Warning: uksort() expects parameter 2 to be a valid callback, no array or string given in %suksort_variation2.php on line %d
-NULL
-
---int 12345--
-
-Warning: uksort() expects parameter 2 to be a valid callback, no array or string given in %suksort_variation2.php on line %d
-NULL
-
---int -12345--
-
-Warning: uksort() expects parameter 2 to be a valid callback, no array or string given in %suksort_variation2.php on line %d
-NULL
-
---float 10.5--
-
-Warning: uksort() expects parameter 2 to be a valid callback, no array or string given in %suksort_variation2.php on line %d
-NULL
-
---float -10.5--
-
-Warning: uksort() expects parameter 2 to be a valid callback, no array or string given in %suksort_variation2.php on line %d
-NULL
-
---float 12.3456789000e10--
-
-Warning: uksort() expects parameter 2 to be a valid callback, no array or string given in %suksort_variation2.php on line %d
-NULL
-
---float -12.3456789000e10--
-
-Warning: uksort() expects parameter 2 to be a valid callback, no array or string given in %suksort_variation2.php on line %d
-NULL
-
---float .5--
-
-Warning: uksort() expects parameter 2 to be a valid callback, no array or string given in %suksort_variation2.php on line %d
-NULL
-
---empty array--
-
-Warning: uksort() expects parameter 2 to be a valid callback, array must have exactly two members in %suksort_variation2.php on line %d
-NULL
-
---int indexed array--
-
-Warning: uksort() expects parameter 2 to be a valid callback, array must have exactly two members in %suksort_variation2.php on line %d
-NULL
-
---associative array--
-
-Warning: uksort() expects parameter 2 to be a valid callback, first array member is not a valid class name or object in %suksort_variation2.php on line %d
-NULL
-
---nested arrays--
-
-Warning: uksort() expects parameter 2 to be a valid callback, array must have exactly two members in %suksort_variation2.php on line %d
-NULL
-
---uppercase NULL--
-
-Warning: uksort() expects parameter 2 to be a valid callback, no array or string given in %suksort_variation2.php on line %d
-NULL
-
---lowercase null--
-
-Warning: uksort() expects parameter 2 to be a valid callback, no array or string given in %suksort_variation2.php on line %d
-NULL
-
---lowercase true--
-
-Warning: uksort() expects parameter 2 to be a valid callback, no array or string given in %suksort_variation2.php on line %d
-NULL
-
---lowercase false--
-
-Warning: uksort() expects parameter 2 to be a valid callback, no array or string given in %suksort_variation2.php on line %d
-NULL
-
---uppercase TRUE--
-
-Warning: uksort() expects parameter 2 to be a valid callback, no array or string given in %suksort_variation2.php on line %d
-NULL
-
---uppercase FALSE--
-
-Warning: uksort() expects parameter 2 to be a valid callback, no array or string given in %suksort_variation2.php on line %d
-NULL
-
---empty string DQ--
-
-Warning: uksort() expects parameter 2 to be a valid callback, function '' not found or invalid function name in %suksort_variation2.php on line %d
-NULL
-
---empty string SQ--
-
-Warning: uksort() expects parameter 2 to be a valid callback, function '' not found or invalid function name in %suksort_variation2.php on line %d
-NULL
-
---instance of classWithToString--
-
-Warning: uksort() expects parameter 2 to be a valid callback, no array or string given in %suksort_variation2.php on line %d
-NULL
-
---instance of classWithoutToString--
-
-Warning: uksort() expects parameter 2 to be a valid callback, no array or string given in %suksort_variation2.php on line %d
-NULL
-
---undefined var--
-
-Warning: uksort() expects parameter 2 to be a valid callback, no array or string given in %suksort_variation2.php on line %d
-NULL
-
---unset var--
-
-Warning: uksort() expects parameter 2 to be a valid callback, no array or string given in %suksort_variation2.php on line %d
-NULL
-===DONE===
diff --git a/ext/standard/tests/array/usort_variation1.phpt b/ext/standard/tests/array/usort_variation1.phpt
deleted file mode 100644
index 14d740dd86..0000000000
--- a/ext/standard/tests/array/usort_variation1.phpt
+++ /dev/null
@@ -1,236 +0,0 @@
---TEST--
-Test usort() function : usage variations - Pass different data types as $array_arg arg
---FILE--
-<?php
-/* Prototype : bool usort(array $array_arg, string $cmp_function)
- * Description: Sort an array by values using a user-defined comparison function
- * Source code: ext/standard/array.c
- */
-
-/*
- * Pass different data types as $array_arg argument to usort() to test behaviour
- */
-
-echo "*** Testing usort() : usage variations ***\n";
-
-// Initialise function arguments not being substituted
-function cmp_function($value1, $value2)
-{
- if($value1 == $value2) {
- return 0;
- }
- else if($value1 > $value2) {
- return 1;
- }
- else {
- return -1;
- }
-}
-
-//get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// get a class
-class classA
-{
- public function __toString() {
- return "Class A object";
- }
-}
-
-// heredoc string
-$heredoc = <<<EOT
-hello world
-EOT;
-
-// get a resource variable
-$fp = fopen(__FILE__, "r");
-
-// unexpected values to be passed to $array_arg argument
-$inputs = array(
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 12.3456789000e10,
- 12.3456789000E-10,
- .5,
-
- // null data
-/*10*/ NULL,
- null,
-
- // boolean data
-/*12*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*16*/ "",
- '',
- array(),
-
- // string data
-/*19*/ "string",
- 'string',
- $heredoc,
-
- // object data
-/*22*/ new classA(),
-
- // undefined data
-/*23*/ @$undefined_var,
-
- // unset data
-/*24*/ @$unset_var,
-
- // resource variable
-/*25*/ $fp
-);
-
-// loop through each element of $inputs to check the behavior of usort()
-$iterator = 1;
-foreach($inputs as $input) {
- echo "\n-- Iteration $iterator --\n";
- var_dump( usort($input, 'cmp_function') );
- $iterator++;
-};
-
-//closing resource
-fclose($fp);
-?>
-===DONE===
---EXPECTF--
-*** Testing usort() : usage variations ***
-
--- Iteration 1 --
-
-Warning: usort() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 2 --
-
-Warning: usort() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 3 --
-
-Warning: usort() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 4 --
-
-Warning: usort() expects parameter 1 to be array, int given in %s on line %d
-NULL
-
--- Iteration 5 --
-
-Warning: usort() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 6 --
-
-Warning: usort() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 7 --
-
-Warning: usort() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 8 --
-
-Warning: usort() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 9 --
-
-Warning: usort() expects parameter 1 to be array, float given in %s on line %d
-NULL
-
--- Iteration 10 --
-
-Warning: usort() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 11 --
-
-Warning: usort() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 12 --
-
-Warning: usort() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 13 --
-
-Warning: usort() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 14 --
-
-Warning: usort() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 15 --
-
-Warning: usort() expects parameter 1 to be array, bool given in %s on line %d
-NULL
-
--- Iteration 16 --
-
-Warning: usort() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 17 --
-
-Warning: usort() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 18 --
-bool(true)
-
--- Iteration 19 --
-
-Warning: usort() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 20 --
-
-Warning: usort() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 21 --
-
-Warning: usort() expects parameter 1 to be array, string given in %s on line %d
-NULL
-
--- Iteration 22 --
-
-Warning: usort() expects parameter 1 to be array, object given in %s on line %d
-NULL
-
--- Iteration 23 --
-
-Warning: usort() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 24 --
-
-Warning: usort() expects parameter 1 to be array, null given in %s on line %d
-NULL
-
--- Iteration 25 --
-
-Warning: usort() expects parameter 1 to be array, resource given in %s on line %d
-NULL
-===DONE===
diff --git a/ext/standard/tests/array/usort_variation2.phpt b/ext/standard/tests/array/usort_variation2.phpt
deleted file mode 100644
index 9e31b2fcbf..0000000000
--- a/ext/standard/tests/array/usort_variation2.phpt
+++ /dev/null
@@ -1,242 +0,0 @@
---TEST--
-Test usort() function : usage variations - Pass different data types as $cmp_function arg
---FILE--
-<?php
-/* Prototype : bool usort(array $array_arg, string $cmp_function)
- * Description: Sort an array by values using a user-defined comparison function
- * Source code: ext/standard/array.c
- */
-
-/*
- * Pass different data types as $cmp_function argument to usort() to test behaviour
- */
-
-echo "*** Testing usort() : usage variation ***\n";
-
-// Class definition for object variable
-class MyClass
-{
- public function __toString()
- {
- return 'object';
- }
-}
-
-$array_arg = array(0 => 1, 1 => -1, 2 => 3, 3 => 10, 4 => 4, 5 => 2, 6 => 8, 7 => 5);
-
-// Get an unset variable
-$unset_var = 10;
-unset ($unset_var);
-
-// Get resource variable
-$fp = fopen(__FILE__,'r');
-
-// different values for $cmp_function
-$inputs = array(
-
- // int data
-/*1*/ 0,
- 1,
- 12345,
- -2345,
-
- // float data
-/*5*/ 10.5,
- -10.5,
- 10.1234567e8,
- 10.7654321E-8,
- .5,
-
- // array data
-/*10*/ array(),
- array(0),
- array(1),
- array(1, 2),
- array('color' => 'red', 'item' => 'pen'),
-
- // null data
-/*15*/ NULL,
- null,
-
- // boolean data
-/*17*/ true,
- false,
- TRUE,
- FALSE,
-
- // empty data
-/*21*/ "",
- '',
-
- // string data
- "string",
- 'string',
-
- // object data
-/*25*/ new MyClass(),
-
- // resource data
- $fp,
-
- // undefined data
- @$undefined_var,
-
- // unset data
-/*28*/ @$unset_var,
-);
-
-// loop through each element of $inputs to check the behavior of usort()
-$iterator = 1;
-foreach($inputs as $input) {
- echo "\n-- Iteration $iterator --\n";
- var_dump( usort($array_arg, $input) );
- $iterator++;
-};
-
-//closing resource
-fclose($fp);
-?>
-===DONE===
---EXPECTF--
-*** Testing usort() : usage variation ***
-
--- Iteration 1 --
-
-Warning: usort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
--- Iteration 2 --
-
-Warning: usort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
--- Iteration 3 --
-
-Warning: usort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
--- Iteration 4 --
-
-Warning: usort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
--- Iteration 5 --
-
-Warning: usort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
--- Iteration 6 --
-
-Warning: usort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
--- Iteration 7 --
-
-Warning: usort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
--- Iteration 8 --
-
-Warning: usort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
--- Iteration 9 --
-
-Warning: usort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
--- Iteration 10 --
-
-Warning: usort() expects parameter 2 to be a valid callback, array must have exactly two members in %s on line %d
-NULL
-
--- Iteration 11 --
-
-Warning: usort() expects parameter 2 to be a valid callback, array must have exactly two members in %s on line %d
-NULL
-
--- Iteration 12 --
-
-Warning: usort() expects parameter 2 to be a valid callback, array must have exactly two members in %s on line %d
-NULL
-
--- Iteration 13 --
-
-Warning: usort() expects parameter 2 to be a valid callback, first array member is not a valid class name or object in %s on line %d
-NULL
-
--- Iteration 14 --
-
-Warning: usort() expects parameter 2 to be a valid callback, first array member is not a valid class name or object in %s on line %d
-NULL
-
--- Iteration 15 --
-
-Warning: usort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
--- Iteration 16 --
-
-Warning: usort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
--- Iteration 17 --
-
-Warning: usort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
--- Iteration 18 --
-
-Warning: usort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
--- Iteration 19 --
-
-Warning: usort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
--- Iteration 20 --
-
-Warning: usort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
--- Iteration 21 --
-
-Warning: usort() expects parameter 2 to be a valid callback, function '' not found or invalid function name in %s on line %d
-NULL
-
--- Iteration 22 --
-
-Warning: usort() expects parameter 2 to be a valid callback, function '' not found or invalid function name in %s on line %d
-NULL
-
--- Iteration 23 --
-
-Warning: usort() expects parameter 2 to be a valid callback, function 'string' not found or invalid function name in %s on line %d
-NULL
-
--- Iteration 24 --
-
-Warning: usort() expects parameter 2 to be a valid callback, function 'string' not found or invalid function name in %s on line %d
-NULL
-
--- Iteration 25 --
-
-Warning: usort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
--- Iteration 26 --
-
-Warning: usort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
--- Iteration 27 --
-
-Warning: usort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-
--- Iteration 28 --
-
-Warning: usort() expects parameter 2 to be a valid callback, no array or string given in %s on line %d
-NULL
-===DONE===