|
1 | 1 | <?xml version="1.0" encoding="UTF-8"?> |
2 | 2 | <project name="app" basedir="."> |
3 | 3 |
|
4 | | - <condition property="ext" value=".bat"> |
5 | | - <os family="windows"/> |
6 | | - </condition> |
7 | | - |
8 | | - <condition property="ext" value=".bat" else=""> |
9 | | - <os family="windows"/> |
10 | | - </condition> |
11 | | - |
12 | | - <target name="phpunit" description="Run PHPUnit"> |
13 | | - <exec executable="${basedir}/vendor/bin/phpunit${ext}" searchpath="true" resolveexecutable="true" failonerror="true" taskname="phpunit"> |
14 | | - <arg value="--configuration"/> |
15 | | - <arg path="${basedir}/phpunit.xml"/> |
16 | | - </exec> |
17 | | - </target> |
18 | | - |
19 | | - <target name="phpunit-coverage" description="Run unit tests with PHPUnit with coverage"> |
20 | | - <delete dir="${basedir}/build/coverage"/> |
21 | | - <mkdir dir="${basedir}/build/coverage"/> |
22 | | - <exec executable="${basedir}/vendor/bin/phpunit${ext}" searchpath="true" resolveexecutable="true" |
23 | | - failonerror="true" taskname="phpunit-coverage"> |
24 | | - <arg value="--coverage-text"/> |
25 | | - <arg value="--configuration"/> |
26 | | - <arg path="${basedir}/phpunit.xml"/> |
27 | | - <arg value="--coverage-clover"/> |
28 | | - <arg path="${basedir}/build/logs/clover.xml"/> |
29 | | - <arg value="--coverage-html"/> |
30 | | - <arg path="${basedir}/build/coverage"/> |
31 | | - </exec> |
32 | | - </target> |
33 | | - |
34 | 4 | <target name="fix-style" description="Code style fixer"> |
35 | 5 | <mkdir dir="${basedir}/build"/> |
36 | 6 | <get src="http://cs.sensiolabs.org/download/php-cs-fixer-v2.phar" dest="${basedir}/build/php-cs-fixer.phar" skipexisting="true"/> |
|
49 | 19 | </exec> |
50 | 20 | </target> |
51 | 21 |
|
52 | | - <target name="phpstan" description="PHP Static Analysis Tool - discover bugs in your code without running it"> |
53 | | - <mkdir dir="${basedir}/build"/> |
54 | | - <get src="https://github.com/phpstan/phpstan/releases/download/0.9.2/phpstan.phar" |
55 | | - dest="${basedir}/build/phpstan.phar" skipexisting="true"/> |
56 | | - <exec executable="php" searchpath="true" resolveexecutable="true" failonerror="true"> |
57 | | - <arg value="${basedir}/build/phpstan.phar"/> |
58 | | - <arg value="analyse"/> |
59 | | - <arg value="-l"/> |
60 | | - <arg value="5"/> |
61 | | - <arg value="src"/> |
62 | | - <arg value="tests"/> |
63 | | - <arg value="--no-interaction"/> |
64 | | - <arg value="--no-progress"/> |
65 | | - </exec> |
66 | | - </target> |
67 | | - |
68 | | - <target name="check-travis" depends="check-style,phpstan"/> |
69 | | - |
70 | 22 | </project> |
0 commit comments