Hello everyone, i'm trying to exclude several files from the cobertura overview. These files are containing GUI-code, which doesn't need to be tested.
My directory structure: |-tld.example.project |--tld.example.project.database |--tld.example.project.gui |---... |---tld.example.project.gui.configuration |----tld.example.project.gui.configuration.users |----... |--tld.example.project.logic I'm trying to exclude tld.example.project.gui and all subpackages from cobertura. Thus I tried the following pom.xml according to the documentation and a lot of blogs and forumposts in the web: <project> ... <build> ... <plugins> ... <plugin> <groupId>org.codehaus.mojo</groupId> <artifactId>cobertura-maven-plugin</artifactId> <version>2.2</version> <configuration> <instrumentation> <excludes> <exclude>tld.example.project.gui.*</exclude> </excludes> <ignores> <ignore>tld/example/project/gui/**/*</ignore> </ignores> </instrumentation> </configuration> <executions> <execution> <id>clean</id> <phase>pre-site</phase> <goals> <goal>clean</goal> </goals> </execution> <execution> <id>instrument</id> <phase>site</phase> <goals> <goal>instrument</goal> <goal>cobertura</goal> <goal>check</goal> </goals> </execution> </executions> </plugin> </plugins> </build> <reporting> <plugins> <plugin> <groupId>org.codehaus.mojo</groupId> <artifactId>cobertura-maven-plugin</artifactId> </plugin> </plugins> </reporting> </project> But this led to the same result as before I added the exclusions and ignores. To dig to the cause, I switched on the debug-output: [DEBUG] Setting context classloader for plugin to: /plugins/org.codehaus.mojo:cobertura-maven-plugin:2...@48/thread:main (instance is: ClassRealm[/plugins/org.codehaus.mojo:cobertura-maven-plugin:2...@48/thread:m ain, parent: ClassRealm[plexus.core, parent: null]]) [DEBUG] Config : <ConfigInstrumentation basedir="C:\Stuff\eclipse\myproject\target\generated-classes\cobertura" includes="**/*.class" /> [DEBUG] Basedir: C:\Stuff\eclipse\myproject\target\generated-classes\cobertura [DEBUG] Include: **/*.class [DEBUG] Exclude: **/*~,**/#*#,**/.#*,**/%*%,**/._*,**/CVS,**/CVS/**,**/.cvsignore,**/SCCS,**/ SCCS/**,**/vssver.scc,**/.svn,**/.svn/**,**/.arch-ids,**/.arch-ids/**,**/.DS _Store As you can see, nothing from the above rules gets excluded. I don't understand why? What am I overseeing? Thank you very much in advance! Uli --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email