|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
[2015-07-09 12:53 UTC] james at asgrim dot com
Description:
------------
The ReflectionClass_FileInfo_basic.phpt test is failing.
When creating a reflection of a class in a .phpt test, the getFileName() method returns simply a string with a hypen ("-") instead of the actual filename.
--- Expected
+++ Actual
@@ @@
-string(%d) "%sReflectionClass_FileInfo_basic.php"
+string(1) "-"
https://github.com/php/php-src/blob/master/ext/reflection/tests/ReflectionClass_FileInfo_basic.phpt
Expected result:
----------------
Expect the filename returned by getFileName() to be "%sReflectionClass_FileInfo_basic.php"
Actual result:
--------------
The filename returned by getFileName() is actually "-"
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Thu Nov 06 17:00:01 2025 UTC |
Ah, interesting! I didn't know that PHPUnit is able to run phpt tests. Anyway, I gave it a try on Windows, and got the following: --- Expected +++ Actual @@ @@ -string(%d) "%sReflectionClass_FileInfo_basic.php" +string(43) "C:\Users\cmb\AppData\Local\Temp\PHP2C57.tmp" So indeed, this seems to be a current limitation of PHPUnit.