1 <?xml version="1.0" encoding="UTF-8"?>
3 <project name="friendica" default="test">
4 <!-- set up include directories, this is necessary for the tests to work -->
7 get_include_path() . PATH_SEPARATOR
8 . 'include' . PATH_SEPARATOR
9 . 'library' . PATH_SEPARATOR
10 . 'library/phpsec' . PATH_SEPARATOR
14 <!-- ====================================================== -->
15 <!-- Target: clean-test -->
16 <!-- deletes directories with old test reports -->
17 <!-- ====================================================== -->
18 <target name="clean-test">
19 <delete dir="report" />
22 <!-- ====================================================== -->
23 <!-- Target: prepare-test -->
24 <!-- creates directories for test reports -->
25 <!-- ====================================================== -->
26 <target name="prepare-test" depends="clean-test">
27 <mkdir dir="report" />
30 <!-- =================================== -->
32 <!-- this target runs all test files -->
33 <!-- =================================== -->
34 <target name="test" depends="prepare-test">
35 <coverage-setup database="./report/coverage-database">
37 <include name="**/*.php" />
38 <exclude name="*test.php"/>
39 <exclude name="./index.php"/>
40 <exclude name="./library/**"/>
41 <exclude name="doc/**"/>
44 <phpunit printsummary="true" >
47 <include name="*test.php" />
50 <formatter type="xml" todir="report" outfile="testlog.xml" />
52 <phpunitreport infile="report/testlog.xml" todir="report" />
53 <coverage-report outfile="report/coverage-database">
54 <report todir="report" styledir="/home/phing/etc" />
58 <!-- ===================================================== -->
59 <!-- Target: clean-doc -->
60 <!-- this target removes documentation from a previous run -->
61 <!-- ===================================================== -->
62 <target name="doc-clean">
63 <echo msg="Removing old documentation..." />
64 <delete dir="./doc/api/" />
65 <echo msg="Generate documentation directory..." />
66 <mkdir dir="./doc/api/" />
69 <!-- ====================================== -->
71 <!-- this target builds all documentation -->
72 <!-- ====================================== -->
73 <target name="doc" depends="doc-clean">
74 <echo msg="Building documentation..." />
75 <docblox title="Friendica API" destdir="./doc/api">
77 <include name="**/*.php" />