Till Westmann | ea8ab39 | 2013-06-05 15:17:08 -0700 | [diff] [blame] | 1 | <!-- |
Ian Maxon | 928bbd1 | 2015-09-14 17:12:48 -0700 | [diff] [blame] | 2 | ! Licensed to the Apache Software Foundation (ASF) under one |
| 3 | ! or more contributor license agreements. See the NOTICE file |
| 4 | ! distributed with this work for additional information |
| 5 | ! regarding copyright ownership. The ASF licenses this file |
| 6 | ! to you under the Apache License, Version 2.0 (the |
| 7 | ! "License"); you may not use this file except in compliance |
| 8 | ! with the License. You may obtain a copy of the License at |
| 9 | ! |
| 10 | ! http://www.apache.org/licenses/LICENSE-2.0 |
| 11 | ! |
| 12 | ! Unless required by applicable law or agreed to in writing, |
| 13 | ! software distributed under the License is distributed on an |
| 14 | ! "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY |
| 15 | ! KIND, either express or implied. See the License for the |
| 16 | ! specific language governing permissions and limitations |
| 17 | ! under the License. |
Till Westmann | ea8ab39 | 2013-06-05 15:17:08 -0700 | [diff] [blame] | 18 | !--> |
khfaraaz82@gmail.com | d02d00f | 2012-09-26 02:08:33 +0000 | [diff] [blame] | 19 | <project> |
| 20 | <target name="instrument"> |
| 21 | <antcall target="instrumentAModule"> |
| 22 | <param name="module" value="asterix-aql"/> |
| 23 | <param name="module" value="asterix-om"/> |
| 24 | <param name="module" value="asterix-metadata"/> |
| 25 | <param name="module" value="asterix-tools"/> |
| 26 | <param name="module" value="asterix-common"/> |
| 27 | <param name="module" value="asterix-transactions"/> |
| 28 | </antcall> |
| 29 | </target> |
| 30 | |
| 31 | <target name="report" depends="merge"> |
| 32 | <property name="src.dir" value="src/main/java/"/> |
| 33 | <cobertura-report datafile="sum.ser" |
| 34 | format="html" |
| 35 | destdir="./target/report"> |
| 36 | <!-- Add all modules that should be included below --> |
| 37 | <!-- fileset dir="./MODULE_NAME_TO_REPLACE/${src.dir}"/ --> |
| 38 | <fileset dir="./asterix-aql/${src.dir}"/> |
| 39 | <fileset dir="./asterix-om/${src.dir}"/> |
| 40 | <fileset dir="./asterix-metadata/${src.dir}"/> |
| 41 | <fileset dir="./asterix-tools/${src.dir}"/> |
| 42 | <fileset dir="./asterix-common/${src.dir}"/> |
| 43 | <fileset dir="./asterix-runtime/${src.dir}"/> |
| 44 | <fileset dir="./asterix-transactions/${src.dir}"/> |
| 45 | </cobertura-report> |
| 46 | </target> |
| 47 | |
| 48 | <target name="merge"> |
| 49 | <cobertura-merge datafile="sum.ser"> |
| 50 | <fileset dir="."> |
| 51 | <include name="**/cobertura.ser"/> |
| 52 | </fileset> |
| 53 | </cobertura-merge> |
| 54 | </target> |
| 55 | |
| 56 | <target name="instrumentAModule"> |
| 57 | <property name="classes.dir" value="target/classes"/> |
| 58 | <cobertura-instrument todir="./${module}/${classes.dir}"> |
| 59 | <fileset dir="./asterix-aql/target/classes"> |
| 60 | <include name="**/*.class"/> |
| 61 | </fileset> |
| 62 | <fileset dir="./asterix-om/target/classes"> |
| 63 | <include name="**/*.class"/> |
| 64 | </fileset> |
| 65 | <fileset dir="./asterix-metadata/target/classes"> |
| 66 | <include name="**/*.class"/> |
| 67 | </fileset> |
| 68 | <fileset dir="./asterix-tools/target/classes"> |
| 69 | <include name="**/*.class"/> |
| 70 | </fileset> |
| 71 | <fileset dir="./asterix-common/target/classes"> |
| 72 | <include name="**/*.class"/> |
| 73 | </fileset> |
| 74 | <fileset dir="./asterix-runtime/target/classes"> |
| 75 | <include name="**/*.class"/> |
| 76 | </fileset> |
| 77 | <fileset dir="./asterix-transactions/target/classes"> |
| 78 | <include name="**/*.class"/> |
| 79 | </fileset> |
| 80 | </cobertura-instrument> |
| 81 | </target> |
| 82 | |
| 83 | <property environment="env"/> |
khfaraaz82@gmail.com | ad15074 | 2012-10-10 02:13:45 +0000 | [diff] [blame] | 84 | <property name="COBERTURA_HOME" value="../../.m2/repository/net/sourceforge/cobertura/cobertura/1.9.4.1"/> |
khfaraaz82@gmail.com | d02d00f | 2012-09-26 02:08:33 +0000 | [diff] [blame] | 85 | <property name="cobertura.dir" value="${COBERTURA_HOME}"/> |
| 86 | <path id="cobertura.classpath"> |
| 87 | <fileset dir="${cobertura.dir}"> |
| 88 | <include name="cobertura.jar"/> |
| 89 | <include name="lib/**/*.jar"/> |
| 90 | </fileset> |
| 91 | </path> |
| 92 | <taskdef classpathref="cobertura.classpath" resource="tasks.properties"/> |
| 93 | </project> |