Add support for filenames as argument for XPCLIScope of ChangeAs with the "unittest" command, the xpcli-Runner will also accept filenames as class names. Rationale
Functionality
The util.cmd.Runner class will check for the first argument containing
the string ".class.php" (or actually, whatever xp::CLASS_FILE_EXT
constant is defined for), and then try to find the class in the classpath. # Use class name $ xpcli fully.qualified.ClassName # Use filename $ xpcli fully/qualified/ClassName.class.php
Note
Using filenames only works if classes are found in the classpath,
otherwise there is no way to infer the classname from the file's name! Security considerations
n/a Speed impact
- Slightly slower: One strstr() check for ".class.php" for every case Dependencies
n/a Related documents
- http://xp-framework.net/rfc/contrib/rfc0133.diff
Implementing patch Comments
- friebe, Sun Jul 29 15:49:00 2007
Implementing patch also contains a couple of bugfixes:
* Markup from method apidocs not correctly textified
* Duplicate @args-check removal
* Positional args numbering off by one in error message
* @args selection not respected in error message | Table of contents |