Phpunit xml file (phpunit.xml)

I am collecting phpunit. I am in the phpunit.xml file.

I want to understand what each element does.

<testsuite name="application">
    <directory>application</directory>
</testsuite>

Does the directory point to a directory containing all * Test.php files?

<filter>
    <whitelist>
        <directory suffix=".php">../application</directory>
        <exclude>
            <directory suffix=".php">../library</directory>
            <directory suffix=".phtml">../application</directory>
            <file>../application/bootstrap.php</file>
            <file>../application/scripts/doctrine.php</file>
        </exclude>
    </whitelist>
</filter>

Does the white list relate to application files (not test.php) that should be covered? Therefore, in this example, I say that I want all php files in .. / application to be covered, except for php files in .. / library, phtml files in .. / application and bootstrap.php and doctrine.php?

+3
source share
1 answer

Not sure what kind of answer you expect, but in both cases you are right.

For the second point:

  • , PHP, , : , "" ( , ).
  • , - , , , .

:

+4

Source: https://habr.com/ru/post/1725369/


All Articles