14ce8a478SDave Kelsey--TEST--
204145dc2SVeres LajosTest function fstat() by substituting argument 1 with emptyUnsetUndefNull values.
34ce8a478SDave Kelsey--FILE--
44ce8a478SDave Kelsey<?php
54ce8a478SDave Kelsey$unset_var = 10;
64ce8a478SDave Kelseyunset($unset_var);
74ce8a478SDave Kelsey
84ce8a478SDave Kelsey$variation_array = array(
94ce8a478SDave Kelsey  'unset var' => @$unset_var,
104ce8a478SDave Kelsey  'undefined var' => @$undefined_var,
114ce8a478SDave Kelsey  'empty string DQ' => "",
124ce8a478SDave Kelsey  'empty string SQ' => '',
134ce8a478SDave Kelsey  'uppercase NULL' => NULL,
144ce8a478SDave Kelsey  'lowercase null' => null,
154ce8a478SDave Kelsey  );
164ce8a478SDave Kelsey
174ce8a478SDave Kelsey
184ce8a478SDave Kelseyforeach ( $variation_array as $var ) {
194ce8a478SDave Kelsey  var_dump(fstat( $var  ) );
204ce8a478SDave Kelsey}
214ce8a478SDave Kelsey?>
224ce8a478SDave Kelsey===DONE===
234ce8a478SDave Kelsey--EXPECTF--
244ce8a478SDave KelseyWarning: fstat() expects parameter 1 to be resource, null given in %s on line %d
254ce8a478SDave Kelseybool(false)
264ce8a478SDave Kelsey
274ce8a478SDave KelseyWarning: fstat() expects parameter 1 to be resource, null given in %s on line %d
284ce8a478SDave Kelseybool(false)
294ce8a478SDave Kelsey
304ce8a478SDave KelseyWarning: fstat() expects parameter 1 to be resource, string given in %s on line %d
314ce8a478SDave Kelseybool(false)
324ce8a478SDave Kelsey
334ce8a478SDave KelseyWarning: fstat() expects parameter 1 to be resource, string given in %s on line %d
344ce8a478SDave Kelseybool(false)
354ce8a478SDave Kelsey
364ce8a478SDave KelseyWarning: fstat() expects parameter 1 to be resource, null given in %s on line %d
374ce8a478SDave Kelseybool(false)
384ce8a478SDave Kelsey
394ce8a478SDave KelseyWarning: fstat() expects parameter 1 to be resource, null given in %s on line %d
404ce8a478SDave Kelseybool(false)
41b746e698SPeter Kokot===DONE===
42