Skip to content

Commit 05995d3

Browse files
Comment <extensions> tag before PHPUnit 9.6 (#1219)
1 parent ae7f097 commit 05995d3

File tree

14 files changed

+171
-0
lines changed

14 files changed

+171
-0
lines changed

phpunit/phpunit/4.7/phpunit.xml.dist

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,8 @@
3030
<listener class="Symfony\Bridge\PhpUnit\SymfonyTestsListener" />
3131
</listeners>
3232

33+
<!-- Uncomment when adding extensions
3334
<extensions>
3435
</extensions>
36+
-->
3537
</phpunit>

phpunit/phpunit/9.3/phpunit.xml.dist

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,8 @@
3333
<listener class="Symfony\Bridge\PhpUnit\SymfonyTestsListener" />
3434
</listeners>
3535

36+
<!-- Uncomment when adding extensions
3637
<extensions>
3738
</extensions>
39+
-->
3840
</phpunit>

phpunit/phpunit/9.6/.env.test

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# define your env variables for the test env here
2+
KERNEL_CLASS='App\Kernel'
3+
APP_SECRET='$ecretf0rt3st'
4+
SYMFONY_DEPRECATIONS_HELPER=999999
5+
PANTHER_APP_ENV=panther
6+
PANTHER_ERROR_SCREENSHOT_DIR=./var/error-screenshots

phpunit/phpunit/9.6/manifest.json

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
{
2+
"copy-from-recipe": {
3+
".env.test": ".env.test",
4+
"phpunit.xml.dist": "phpunit.xml.dist",
5+
"tests/": "tests/"
6+
},
7+
"gitignore": [
8+
"/phpunit.xml",
9+
".phpunit.result.cache"
10+
]
11+
}

phpunit/phpunit/9.6/phpunit.xml.dist

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
3+
<!-- https://phpunit.readthedocs.io/en/latest/configuration.html -->
4+
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
5+
xsi:noNamespaceSchemaLocation="vendor/phpunit/phpunit/phpunit.xsd"
6+
backupGlobals="false"
7+
colors="true"
8+
bootstrap="tests/bootstrap.php"
9+
convertDeprecationsToExceptions="false"
10+
>
11+
<php>
12+
<ini name="display_errors" value="1" />
13+
<ini name="error_reporting" value="-1" />
14+
<server name="APP_ENV" value="test" force="true" />
15+
<server name="SHELL_VERBOSITY" value="-1" />
16+
<server name="SYMFONY_PHPUNIT_REMOVE" value="" />
17+
<server name="SYMFONY_PHPUNIT_VERSION" value="9.5" />
18+
</php>
19+
20+
<testsuites>
21+
<testsuite name="Project Test Suite">
22+
<directory>tests</directory>
23+
</testsuite>
24+
</testsuites>
25+
26+
<coverage processUncoveredFiles="true">
27+
<include>
28+
<directory suffix=".php">src</directory>
29+
</include>
30+
</coverage>
31+
32+
<listeners>
33+
<listener class="Symfony\Bridge\PhpUnit\SymfonyTestsListener" />
34+
</listeners>
35+
36+
<extensions>
37+
</extensions>
38+
</phpunit>
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
<?php
2+
3+
use Symfony\Component\Dotenv\Dotenv;
4+
5+
require dirname(__DIR__).'/vendor/autoload.php';
6+
7+
if (file_exists(dirname(__DIR__).'/config/bootstrap.php')) {
8+
require dirname(__DIR__).'/config/bootstrap.php';
9+
} elseif (method_exists(Dotenv::class, 'bootEnv')) {
10+
(new Dotenv())->bootEnv(dirname(__DIR__).'/.env');
11+
}

symfony/phpunit-bridge/5.1/phpunit.xml.dist

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,8 @@
3131
<listener class="Symfony\Bridge\PhpUnit\SymfonyTestsListener" />
3232
</listeners>
3333

34+
<!-- Uncomment when adding extensions
3435
<extensions>
3536
</extensions>
37+
-->
3638
</phpunit>

symfony/phpunit-bridge/5.3/phpunit.xml.dist

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,8 @@
3333
<listener class="Symfony\Bridge\PhpUnit\SymfonyTestsListener" />
3434
</listeners>
3535

36+
<!-- Uncomment when adding extensions
3637
<extensions>
3738
</extensions>
39+
-->
3840
</phpunit>

symfony/phpunit-bridge/6.3/.env.test

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# define your env variables for the test env here
2+
KERNEL_CLASS='App\Kernel'
3+
APP_SECRET='$ecretf0rt3st'
4+
SYMFONY_DEPRECATIONS_HELPER=999999
5+
PANTHER_APP_ENV=panther
6+
PANTHER_ERROR_SCREENSHOT_DIR=./var/error-screenshots
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
#!/usr/bin/env php
2+
<?php
3+
4+
if (!ini_get('date.timezone')) {
5+
ini_set('date.timezone', 'UTC');
6+
}
7+
8+
if (is_file(dirname(__DIR__).'/vendor/phpunit/phpunit/phpunit')) {
9+
define('PHPUNIT_COMPOSER_INSTALL', dirname(__DIR__).'/vendor/autoload.php');
10+
require PHPUNIT_COMPOSER_INSTALL;
11+
PHPUnit\TextUI\Command::main();
12+
} else {
13+
if (!is_file(dirname(__DIR__).'/vendor/symfony/phpunit-bridge/bin/simple-phpunit.php')) {
14+
echo "Unable to find the `simple-phpunit.php` script in `vendor/symfony/phpunit-bridge/bin/`.\n";
15+
exit(1);
16+
}
17+
18+
require dirname(__DIR__).'/vendor/symfony/phpunit-bridge/bin/simple-phpunit.php';
19+
}

0 commit comments

Comments
 (0)