mirror of
https://github.com/php/php-src.git
synced 2025-01-10 21:14:37 +08:00
c621d4f63f
- Fix #45345 (getPathInfo on the file instead of the dir) - Remove trailing / on input
23 lines
419 B
PHP
23 lines
419 B
PHP
--TEST--
|
|
SPL: SplFileObject realpath and include_path
|
|
--FILE--
|
|
<?php
|
|
|
|
set_include_path('tests');
|
|
|
|
chdir(dirname(dirname(__FILE__))); // ext/spl
|
|
|
|
|
|
$fo = new SplFileObject('fileobject_004.phpt', 'r', true);
|
|
|
|
var_dump($fo->getPath());
|
|
var_dump($fo->getFilename());
|
|
var_dump($fo->getRealPath());
|
|
?>
|
|
==DONE==
|
|
--EXPECTF--
|
|
%s(%d) "%sspl%stests"
|
|
%s(19) "fileobject_004.phpt"
|
|
%s(%d) "%sspl%stests%sfileobject_004.phpt"
|
|
==DONE==
|