--TEST-- Test function gzfile() by substituting argument 2 with object values. --SKIPIF-- --FILE-- new classWithToString(), 'instance of classWithoutToString' => new classWithoutToString(), ); foreach ( $variation as $var ) { var_dump(gzfile( $filename, $var ) ); } ?> ===DONE=== --EXPECTF-- Error: 2 - gzfile() expects parameter 2 to be long, object given, %s(%d) NULL Error: 2 - gzfile() expects parameter 2 to be long, object given, %s(%d) NULL ===DONE===