wallabag/build.xml
Jeremy 276a1e9d3f And phpunit with html coverage to ant
Launching `ant phpunit` will now generate HTML Coverage
2015-04-01 21:32:02 +02:00

51 lines
1.7 KiB
XML

<?xml version="1.0" encoding="UTF-8"?>
<project name="wallabag" default="build">
<target name="build" depends="prepare"/>
<target name="clean" description="Cleanup build artifacts">
<delete dir="${basedir}/app/cache"/>
</target>
<target name="prepare" depends="clean" description="Prepare for build">
<exec executable="composer">
<arg value="install"/>
<arg value="--no-interaction"/>
<arg value="--no-progress"/>
</exec>
<exec executable="php">
<arg value="${basedir}/app/console"/>
<arg value="doctrine:database:drop"/>
<arg value="--force"/>
<arg value="--env=test"/>
</exec>
<exec executable="php">
<arg value="${basedir}/app/console"/>
<arg value="doctrine:database:create"/>
<arg value="--env=test"/>
</exec>
<exec executable="php">
<arg value="${basedir}/app/console"/>
<arg value="doctrine:schema:create"/>
<arg value="--env=test"/>
</exec>
<exec executable="php">
<arg value="${basedir}/app/console"/>
<arg value="cache:clear"/>
<arg value="--env=test"/>
</exec>
<exec executable="php">
<arg value="${basedir}/app/console"/>
<arg value="doctrine:fixtures:load"/>
<arg value="--no-interaction"/>
<arg value="--env=test"/>
</exec>
</target>
<target name="phpunit" description="Run unit tests with PHPUnit + HTML Coverage">
<exec executable="phpunit" failonerror="true">
<arg value="--coverage-html"/>
<arg value="build/coverage"/>
</exec>
</target>
</project>