18f9ec423SDave Kelsey--TEST--
204145dc2SVeres LajosTest function readgzfile() by substituting argument 1 with array values.
38f9ec423SDave Kelsey--SKIPIF--
48f9ec423SDave Kelsey<?php
58f9ec423SDave Kelseyif (!extension_loaded('zlib')) die ('skip zlib extension not available in this build');
68f9ec423SDave Kelsey?>
78f9ec423SDave Kelsey--FILE--
88f9ec423SDave Kelsey<?php
98f9ec423SDave Kelsey
108f9ec423SDave Kelsey
118f9ec423SDave Kelsey$use_include_path = false;
128f9ec423SDave Kelsey
138f9ec423SDave Kelsey
148f9ec423SDave Kelsey$index_array = array(1, 2, 3);
158f9ec423SDave Kelsey$assoc_array = array(1 => 'one', 2 => 'two');
168f9ec423SDave Kelsey
178f9ec423SDave Kelsey$variation = array(
188f9ec423SDave Kelsey  'empty array' => array(),
198f9ec423SDave Kelsey  'int indexed array' => $index_array,
208f9ec423SDave Kelsey  'associative array' => $assoc_array,
218f9ec423SDave Kelsey  'nested arrays' => array('foo', $index_array, $assoc_array),
228f9ec423SDave Kelsey  );
238f9ec423SDave Kelsey
248f9ec423SDave Kelsey
258f9ec423SDave Kelseyforeach ( $variation as $var ) {
268f9ec423SDave Kelsey  var_dump(readgzfile( $var ,  $use_include_path ) );
278f9ec423SDave Kelsey}
288f9ec423SDave Kelsey?>
298f9ec423SDave Kelsey===DONE===
308f9ec423SDave Kelsey--EXPECTF--
31a643ccfbSStanislav MalyshevWarning: readgzfile() expects parameter 1 to be a valid path, array given in %s on line %d
328f9ec423SDave KelseyNULL
338f9ec423SDave Kelsey
34a643ccfbSStanislav MalyshevWarning: readgzfile() expects parameter 1 to be a valid path, array given in %s on line %d
358f9ec423SDave KelseyNULL
368f9ec423SDave Kelsey
37a643ccfbSStanislav MalyshevWarning: readgzfile() expects parameter 1 to be a valid path, array given in %s on line %d
388f9ec423SDave KelseyNULL
398f9ec423SDave Kelsey
40a643ccfbSStanislav MalyshevWarning: readgzfile() expects parameter 1 to be a valid path, array given in %s on line %d
418f9ec423SDave KelseyNULL
42a643ccfbSStanislav Malyshev===DONE===
43