Skip to content

Commit 9a12ad1

Browse files
jrfnlgrogy
authored andcommitted
PHPUnit: improve configuration
Move the CLI arguments which can be placed in the configuration file to the configuration file and removed them from the Ant build configuration.
1 parent bc17214 commit 9a12ad1

File tree

2 files changed

+10
-8
lines changed

2 files changed

+10
-8
lines changed

build.xml

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -65,9 +65,7 @@
6565
<delete file="${basedir}/build/logs/phpunit.xml" quiet="true" />
6666

6767
<exec executable="${phpunit}" failonerror="true">
68-
<arg line='--configuration ${basedir}/phpunit.xml.dist' />
69-
<arg line='-d memory_limit=256M' />
70-
<arg line='--log-junit "${basedir}/build/logs/phpunit.xml"' />
68+
<arg line='--no-coverage' />
7169
<arg line='${colors-arg.color}' />
7270
</exec>
7371
</target>
@@ -79,11 +77,6 @@
7977
<mkdir dir="${basedir}/build/coverage" />
8078

8179
<exec executable="${phpunit}" failonerror="true">
82-
<arg line='--configuration ${basedir}/phpunit.xml.dist' />
83-
<arg line='-d memory_limit=256M' />
84-
<arg line='--log-junit "${basedir}/build/logs/phpunit.xml"' />
85-
<arg line='--coverage-clover "${basedir}/build/logs/clover.xml"' />
86-
<arg line='--coverage-html "${basedir}/build/coverage/"' />
8780
<arg line='${colors-arg.color}' />
8881
</exec>
8982
</target>

phpunit.xml.dist

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,4 +16,13 @@
1616
</whitelist>
1717
</filter>
1818

19+
<logging>
20+
<log type="junit" target="build/logs/phpunit.xml"/>
21+
<log type="coverage-clover" target="build/logs/clover.xml"/>
22+
<log type="coverage-html" target="build/coverage/"/>
23+
</logging>
24+
25+
<php>
26+
<ini name="memory_limit" value="256M"/>
27+
</php>
1928
</phpunit>

0 commit comments

Comments
 (0)