mirror of
https://github.com/php/php-src.git
synced 2026-04-21 15:08:16 +02:00
bd9f4fa676
For rationale, see https://github.com/php/php-src/pull/6787 Make extension checks lowercase, add a special case for opcache that has internal name not matching .so filename. Extensions migrated in part 2: * dom * exif * fileinfo * ffi
23 lines
562 B
PHP
23 lines
562 B
PHP
--TEST--
|
|
Test finfo_close() function : error conditions
|
|
--EXTENSIONS--
|
|
fileinfo
|
|
--FILE--
|
|
<?php
|
|
echo "*** Testing finfo_close() : error conditions ***\n";
|
|
|
|
echo "\n-- Testing finfo_close() function with wrong resource type --\n";
|
|
$fp = fopen( __FILE__, 'r' );
|
|
try {
|
|
var_dump( finfo_close( $fp ) );
|
|
} catch (TypeError $e) {
|
|
echo $e->getMessage(), "\n";
|
|
}
|
|
|
|
?>
|
|
--EXPECT--
|
|
*** Testing finfo_close() : error conditions ***
|
|
|
|
-- Testing finfo_close() function with wrong resource type --
|
|
finfo_close(): Argument #1 ($finfo) must be of type finfo, resource given
|