File tree 2 files changed +21
-0
lines changed
src/Symfony/Bridge/PhpUnit 2 files changed +21
-0
lines changed Original file line number Diff line number Diff line change 1
1
CHANGELOG
2
2
=========
3
3
4
+ 4.1.0
5
+ -----
6
+
7
+ * Search for ` SYMFONY_PHPUNIT_REMOVE ` env var in ` phpunit.xml ` then
8
+ ` phpunit.xml.dist `
9
+
4
10
4.0.0
5
11
-----
6
12
Original file line number Diff line number Diff line change @@ -53,6 +53,21 @@ $COMPOSER = file_exists($COMPOSER = $oldPwd.'/composer.phar') || ($COMPOSER = rt
53
53
54
54
if (false === $ SYMFONY_PHPUNIT_REMOVE = getenv ('SYMFONY_PHPUNIT_REMOVE ' )) {
55
55
$ SYMFONY_PHPUNIT_REMOVE = 'phpspec/prophecy symfony/yaml ' ;
56
+
57
+ $ phpunitConfigFilename = null ;
58
+ if (file_exists ('phpunit.xml ' )) {
59
+ $ phpunitConfigFilename = 'phpunit.xml ' ;
60
+ } elseif (file_exists ('phpunit.xml.dist ' )) {
61
+ $ phpunitConfigFilename = 'phpunit.xml.dist ' ;
62
+ }
63
+ if ($ phpunitConfigFilename ) {
64
+ $ xml = new DomDocument ();
65
+ $ xml ->load ($ phpunitConfigFilename );
66
+ $ var = (new DOMXpath ($ xml ))->query ('//php/env[@name="SYMFONY_PHPUNIT_REMOVE"] ' )[0 ];
67
+ if ($ var ) {
68
+ $ SYMFONY_PHPUNIT_REMOVE = $ var ->getAttribute ('value ' );
69
+ }
70
+ }
56
71
}
57
72
58
73
if (!file_exists ("$ PHPUNIT_DIR /phpunit- $ PHPUNIT_VERSION /phpunit " ) || md5_file (__FILE__ )."\n" .$ SYMFONY_PHPUNIT_REMOVE !== @file_get_contents ("$ PHPUNIT_DIR /. $ PHPUNIT_VERSION .md5 " )) {
You can’t perform that action at this time.
0 commit comments