phpunit.xml.dist 2.59 KB
Newer Older
1 2
<?xml version="1.0" encoding="UTF-8"?>

3
<phpunit bootstrap="tests/bootstrap.php" colors="true">
4 5 6 7 8
  <php>
    <!-- Set error reporting to E_ALL. -->
    <ini name="error_reporting" value="32767"/>
    <!-- Do not limit the amount of memory tests take to run. -->
    <ini name="memory_limit" value="-1"/>
9 10 11 12
    <env name="SIMPLETEST_BASE_URL" value=""/>
    <!-- Example SIMPLETEST_BASE_URL value: http://localhost -->
    <env name="SIMPLETEST_DB" value=""/>
    <!-- Example SIMPLETEST_DB value: mysql://username:password@localhost/databasename#table_prefix -->
13
  </php>
14
  <testsuites>
15 16 17 18 19 20 21 22 23 24
    <testsuite name="unit">
      <directory>./tests/Drupal/Tests</directory>
      <directory>./modules/*/tests/src/Unit</directory>
      <directory>../modules/*/tests/src/Unit</directory>
      <directory>../sites/*/modules/*/tests/src/Unit</directory>
      <!-- Exclude Composer's vendor directory so we don't run tests there. -->
      <exclude>./vendor</exclude>
      <!-- Exclude Drush tests. -->
      <exclude>./drush/tests</exclude>
    </testsuite>
25 26 27 28 29 30 31 32 33 34
    <testsuite name="kernel">
      <directory>./tests/Drupal/KernelTests</directory>
      <directory>./modules/*/tests/src/Kernel</directory>
      <directory>../modules/*/tests/src/Kernel</directory>
      <directory>../sites/*/modules/*/tests/src/Kernel</directory>
      <!-- Exclude Composer's vendor directory so we don't run tests there. -->
      <exclude>./vendor</exclude>
      <!-- Exclude Drush tests. -->
      <exclude>./drush/tests</exclude>
    </testsuite>
35 36 37 38 39
    <testsuite name="functional">
      <directory>./tests/Drupal/FunctionalTests</directory>
      <directory>./modules/*/tests/src/Functional</directory>
      <directory>../modules/*/tests/src/Functional</directory>
      <directory>../sites/*/modules/*/tests/src/Functional</directory>
40 41 42 43
      <!-- Exclude Composer's vendor directory so we don't run tests there. -->
      <exclude>./vendor</exclude>
      <!-- Exclude Drush tests. -->
      <exclude>./drush/tests</exclude>
44 45
    </testsuite>
  </testsuites>
46 47 48 49
  <listeners>
    <listener class="\Drupal\Tests\Standards\DrupalStandardsListener">
    </listener>
  </listeners>
50 51
  <!-- Filter for coverage reports. -->
  <filter>
52 53 54 55 56 57
    <whitelist>
      <directory>./includes</directory>
      <directory>./lib</directory>
      <directory>./modules</directory>
      <directory>../modules</directory>
      <directory>../sites</directory>
58 59 60 61 62
      <!-- By definition test classes have no tests. -->
      <exclude>
        <directory suffix="Test.php">./</directory>
        <directory suffix="TestBase.php">./</directory>
      </exclude>
63
     </whitelist>
64
  </filter>
65
</phpunit>