phpunit.xml配置之后,总是“No tests executed”
The filenames must end with "Test.php". This is what PHPUnit is looking for within directories.
其实这是默认情况,但可以指定文件后缀的(suffix),具体是写在directory
后面,例如这样的:
<?xml version="1.0" encoding="UTF-8"?>
<phpunit bootstrap="vendor/autoload.php"
colors="true"
verbose="true"
stopOnFailure="false">
<testsuites>
<testsuite name="Doraemon Test">
<directory suffix="Tests.php">tests</directory>
</testsuite>
</testsuites>
</phpunit>