Skip to content

Instantly share code, notes, and snippets.

@tobiastom
Created June 23, 2011 16:59
Show Gist options
  • Save tobiastom/1042992 to your computer and use it in GitHub Desktop.
Save tobiastom/1042992 to your computer and use it in GitHub Desktop.
<?xml version="1.0"?>
<project name="Hello World Example" default="build" description="This is an example buildfile for Phing.">
<target name="prepare">
<delete dir="reports"/>
<mkdir dir="reports/coverage"/>
</target>
<target name="build" depends="prepare">
<coverage-setup database="reports/coverage.db">
<fileset dir="src">
<include name="*.php"/>
<exclude name="*Test.php"/>
</fileset>
</coverage-setup>
<phpunit codecoverage="true">
<batchtest>
<fileset dir="src">
<include name="*Test.php"/>
</fileset>
</batchtest>
</phpunit>
<coverage-report outfile="${project.basedir}/reports/coverage.xml">
<report todir="${project.basedir}/reports/coverage"
styledir="/usr/local/Cellar/php53osx/5.3.5/share/pear/data/phing/etc"/>
</coverage-report>
</target>
</project>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment