-
Notifications
You must be signed in to change notification settings - Fork 10
/
build.xml
63 lines (56 loc) · 1.9 KB
/
build.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
<project name="Hoborg CMS" default="help" basedir=".">
<property name="dir.base" location="." />
<property name="dir.doc" location="docs" />
<property name="dir.src.lib" location="lib" />
<property name="dir.tst.unit" location="tests/" />
<property name="dir.tst.bdd" location="features/" />
<property name="dir.logs" value="${dir.base}/logs" />
<target name="prepare" description="Prepares working directory">
<!-- Prepare logs folders -->
<mkdir dir="${dir.logs}" />
<mkdir dir="${dir.logs}/phpmd" />
<mkdir dir="${dir.logs}/phpcs" />
<mkdir dir="${dir.logs}/phpcpd" />
<mkdir dir="${dir.logs}/phpdepend" />
<mkdir dir="${dir.logs}/phpunit" />
<exec executable="git" dir="${dir.base}/lib/Vendor/Doctrine">
<arg line="submodule init" />
</exec>
<exec executable="git" dir="${dir.base}/lib/Vendor/Doctrine">
<arg line="submodule update" />
</exec>
<!-- Initialize Behat2 vendor -->
<exec executable="git" dir="${dir.base}/vendor/Behat2">
<arg line="submodule init" />
</exec>
<exec executable="git" dir="${dir.base}/vendor/Behat2">
<arg line="submodule update" />
</exec>
</target>
<target name="phpunit"
description="Run PHP Unit tests suite."
>
<exec executable="phpunit">
<arg line="-c ${dir.base}/phpunit.xml.dist" />
<arg line="--strict" />
<arg line="--log-junit ${dir.logs}/phpunit/junit.xml" />
<arg line="--testdox-html ${dir.doc}/agile-doc.html" />
<arg line="--coverage-clover ${dir.logs}/phpunit/coverage.xml" />
<arg line="--coverage-html ${dir.logs}/phpunit/" />
<arg value="${dir.tst.unit}" />
</exec>
</target>
<!-- Clean up -->
<target name="clean"
description="Clean up working directory"
>
<delete dir="${dir.logs}" />
</target>
<!-- Help Message -->
<target name="help" description="Prints this help">
<exec executable="ant">
<arg line="-p" />
<arg line="-f ${dir.base}/build-cs.xml" />
</exec>
</target>
</project>